Hi all, I am new to R and have some trouble with exporting results from a non linear squares object (.nls), would be very thankful if anyone could help me.
So what I'm doing is a Bass modelling of some data. The result is stored in the object "Bass.nls". I want to export a matrix with the three columns: observation number, actual observation value, predicted observation value. Can I do this somehow? If not can I export the full nls object somehow? When trying the to export using, write.table(Bass.nls) I get the following error message: Error in as.data.frame.default(x[[i]], optional = TRUE, stringsAsFactors = stringsAsFactors) : cannot coerce class '"nls"' into a data.frame I am thankful for all help I can get! Sincerely yours -- View this message in context: http://r.789695.n4.nabble.com/Export-nls-object-to-text-file-tp4431039p4431039.html Sent from the R help mailing list archive at Nabble.com. ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.