[R] Error in xy.coords(x, y, xlabel, ylabel, log) : x and y lengths differ

ecatchpole e.catchpole at adfa.edu.au
Tue Oct 4 04:29:32 CEST 2005


Try

plot(data.df$temp, data.df$output)

Ted.

On 04/10/05 07:31,  Robbie Turner wrote,:
> I am currently trying to use R to construct a regression model to
> explain output based on temperature. I have combined my output and temp
> data into a notepad file. there is no problem with loading the data into
> R.
> 
>>data.df
>     output temp
> 1    850   17
> 2    849   17
> 3    905   17
> 4    925   17
> 5   1043   19
> 6   1104   20
> 7   1097   18
> 8    979   19
> 9    926   18
> 10  1133   18
> ~~
> ~~
> 240 1124   12
> 241 1344   12
> 242 1375   11
> 243 1359   12
> 
> but when I try to plot the data I keep getting this error:
> 
>>plot(temp,output)
> Error in xy.coords(x, y, xlabel, ylabel, log) : 
>         x and y lengths differ
> 
> any advice on how to over come this error would be greatly appreciated.
> 
> Cheers, Robbie.




More information about the R-help mailing list