[message needed manual approvement: it had a single line "help" -- MM ] I have a table containing two columns and some 600 rows. The first column is a time series in the sense contains the amount of time the model that i am studying stays in a particular state(ie sojourn time). I extract the contents of the table using read.table. and extract the first column from the table as follows. ft <-read.table(<filename>) firstcol <-ft[1]. When I pass firstcol as a parameter to pp.plot(firstcol) I get the following error : Error in if (abs(term) < acc) flag <- "false" : missing value where logical needed Can anyone tell me where the mistake is. end. -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
Ravi Malayambakkam-n <rmalayam at ic.sunysb.edu> writes:> [message needed manual approvement: > it had a single line "help" -- MM ] > > I have a table containing two columns and some 600 rows. The first column > is a time series in the sense contains the amount of time the model that i > am studying stays in a particular state(ie sojourn time). I > extract the contents of the table using read.table. and extract the > first column from the table as follows. > ft <-read.table(<filename>) > firstcol <-ft[1]. > When I pass firstcol as a parameter to pp.plot(firstcol) I get the > following error : > Error in if (abs(term) < acc) flag <- "false" : > missing value where logical needed > > Can anyone tell me where the mistake is.Haven't tried pp.plot, but I would guess that it is because ft[1] is a *data frame* with one column. Try ft[[1]] to get the column vector itself. -- O__ ---- Peter Dalgaard Blegdamsvej 3 c/ /'_ --- Dept. of Biostatistics 2200 Cph. N (*) \(*) -- University of Copenhagen Denmark Ph: (+45) 35327918 ~~~~~~~~~~ - (p.dalgaard at biostat.ku.dk) FAX: (+45) 35327907 -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
On Wed, 24 Apr 2002, Ravi Malayambakkam-n wrote:> [message needed manual approvement: > it had a single line "help" -- MM ] > > I have a table containing two columns and some 600 rows. The first column > is a time series in the sense contains the amount of time the model that i > am studying stays in a particular state(ie sojourn time).That is a vector of times, not a time series, unless the observations are ordered in (calendar) time. If this is a time series, statistical methods that assume independence are probably inappropriate.> I > extract the contents of the table using read.table. and extract the > first column from the table as follows. > ft <-read.table(<filename>) > firstcol <-ft[1]. > When I pass firstcol as a parameter to pp.plot(firstcol) I get the > following error : > Error in if (abs(term) < acc) flag <- "false" : > missing value where logical needed > > Can anyone tell me where the mistake is.Well, you haven't given us anything to reproduce this, not even a traceback(). R does come with quite a few debugging facilities to help you find the error. However, the first thing to do is to check if you passed the right arguments. For pp.plot, this is a vector of angular measurements in radians. That does not match your description! Please send a reproducible example to the maintainers of CircStats. At the least they have been insufficiently defensive against incorrect inputs, and there may be more to it that that. Please also tell them the version of the package you used, and the result of R.version. -- Brian D. Ripley, ripley at stats.ox.ac.uk Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272860 (secr) Oxford OX1 3TG, UK Fax: +44 1865 272595 -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._