I'd like to access/print regular summary output for a model I've looped with purrr::map, but I'm getting an error: "Error: Input must be list of vectors". Any suggestions?
It appears the error is coming from the unnest() function. I'm not sure unnest knows how to handle the class "summary.gam". In the help page, it says unnest is primarily designed to work with lists of data frames. What is your goal with the unnest function? Perhaps I can suggest another function
Ok. Yes, it looks like I spoke too soon and I have the same output in your screenshot. Sorry! Looks like another user offered a solution. You could also pipe to a dollar sign which is probably not ideal:
@zac-garland, I'm not sure that your example makes the m1_smry column callable for output. But it does print the output for everything because the print() function is used. I could pipe this output to a text file for later reference.
I was hoping for a simple method for printing that output at-will from the nested table. But the list structure created by map doesn't seem to lend itself to this.