[R] Error in plot.window(...) : need finite 'ylim' values

Rich Shepard rshepard at appl-ecosys.com
Thu Jan 5 17:55:07 CET 2012


On Thu, 5 Jan 2012, R. Michael Weylandt wrote:

> My initial guess is because you don't have any complete cases: cf.
> this behavior plot(c(NA, NA))

Michael,

   Here's a data frame that does plot; no complete cases here, either:

mahalla.tds.z
            MAH-100 MAH-225 MAH-50 MASH-10 MASH-20 MASH-30 MASHSP-10
1996-03-27      NA     278     NA      NA      NA      NA        NA
1996-04-25     238     250     NA      NA      NA      NA        NA
1996-05-10     232      NA     NA      NA      NA      NA        NA
1996-05-23     226      NA     NA      NA      NA      NA        NA
1996-05-24      NA      NA     NA     136     216     258       162
1996-06-03     196     236     NA      NA      NA      NA        NA
1996-06-07     232      NA     NA      NA      NA      NA        NA
1996-07-18      NA      NA     NA      NA      NA      NA       224
1996-07-22     312      NA    294      NA      NA      NA        NA
1996-08-30     304      NA     NA      NA      NA      NA        NA
1996-09-26     387      NA     NA      NA      NA      NA        NA
1996-10-28     293      NA     NA      NA      NA      NA        NA

> If that's not it, dput() your data so that it's useable by others.

dput(millc.tds.z)
structure(c(NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, 304, 
NA, NA, NA, 320, 500, 545, 570, 518, 458, NA, NA, NA, NA, NA, 
NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, 
NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, 
NA, NA, NA, NA, NA, NA, NA, NA, 193, NA, NA, NA, 232, NA, 249, 
288, 282, 340, NA, NA, 300, 312, NA, NA, NA, NA, 388, 356, 502, 
335, 748, 448, 676, 526, 426, 300, 310, 560, 930, 840, 360, 1100, 
1100, 440, 450, 630, 830, 350, 490, 937, 1070, 548, 464, 1020, 
636, 346, 506, 475, 372, 634, 475, 358, 315, 754, 1050, 280, 
852, 410, 429, 479, 456, 336, 391, 381, 378, NA, 439, 273, 348, 
292, 320, NA, NA, 330, 384, NA, NA, NA, NA, NA, NA, NA, NA, NA, 
NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, 
NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, 395, NA, NA, 374, 
347, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, 
NA, NA, NA, NA, NA, 328, NA, NA, NA, NA, NA, NA, NA, NA, NA, 
NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, 
NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, 
NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, 
NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, 
NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, 
NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, 
NA, NA, NA, NA, NA, NA), .Dim = c(63L, 5L), .Dimnames = list(
     NULL, c("MC-0.5", "MC-1", "MC-2", "MC-30", "MC-50")), index =
structure(c(8785L, 
8848L, 8876L, 8904L, 8929L, 8971L, 9126L, 9212L, 9217L, 9304L, 
9339L, 9581L, 9601L, 9602L, 9659L, 9665L, 9700L, 9730L, 9765L, 
9797L, 9822L, 9948L, 10009L, 10072L, 10332L, 10490L, 10730L, 
10835L, 11046L, 11108L, 11437L, 11837L, 11898L, 11991L, 12139L, 
12201L, 12314L, 12380L, 12507L, 12530L, 12618L, 12745L, 12902L, 
12934L, 12992L, 13109L, 13230L, 13320L, 13467L, 13592L, 13628L, 
13963L, 13965L, 14056L, 14090L, 14330L, 14363L, 14391L, 14475L, 
14559L, 14749L, 14833L, 15112L), class = "Date"), class = "zoo")

Thanks,

Rich



More information about the R-help mailing list