Open jeff-goldsmith opened 4 years ago
just a couple more thoughts on this -- sort of related to 7c0fc0e283654baca12107277d619ac5a7425034
i wrote a function that extracts scores from an fpca object, of the kind returned by rfr_fpca
. that object is a bit different from what you'd get from predict.fpca
(which is just a tfb
...). so, for predict
, you can convert the tfb
to an fpca object and then extract scores.
kinda clunky, but i'm not sure exactly how users are likely to interact with tfb
s and fpca
objects. i suppose we could extract scores from either using the same function, or encourage users to convert tfb
s to full fpca
things if they want to worry about FPCA stuff (and not just represent data using a basis expansion).
also, am i just completely missing some easier option? do we make it simple to extract coefficients from tfb
objects in tidyfun ..?
right now
predict.fpca
returns atfb
object (coefs from scores, basis from fpca). makes a lot of sense, but sometimes people just want the scores and not the fitted values. can we handle that withtype
?ideally this will work smoothly with
modelr
etc too