[R] Help

David Winsemius dwinsemius at comcast.net
Mon May 17 15:26:20 CEST 2010


Please read the Posting Guide. Several of your questions will get  
answered, including why the attachment did not arrive at any of out  
mail clients.

We are having some difficulty understanding why you say your lecturer  
"didn't teach us anything about how to use R". It appears from the  
mangled version of the pasted assignment, that your lecturer _is_  
trying to teach you something by give an entirely worked script. Are  
you perhaps copying the ">" symbols into a console session that is not  
set up to accept such? Or have the data in the wrog location. Who of  
us can possibly know?

I suspect the bottom line is that you need to go to your lecturer's  
office hours, since this list is not set up for basic R tutoring.

-- 
David.

On May 17, 2010, at 9:07 AM, APOLLOCHEROKEE wrote:

>
> Dear Sir or Madam:        Hi,sorry for disturbing you. Currently,  
> I'm a master student, and my lecturer didn't teach us anything about  
> how to use R. But the assignment is all about R. So even a very  
> stupid error,I still can't tell. So please forgive my innocence.
> The following is the requirement of my assignment
> you will read in the data> > uscpi <- read.table("C:/Users/APOLLO/ 
> Desktop/ECC4660/A2/uscpi.csv",header=T,sep=",")> > # Now compute a  
> variable called ss, short for subscript, which you> # can use to  
> index your variables, which will be useful for differencing> > ss <-  
> length(uscpi$year)> > # Compute what Julie Smith would refer to as  
> the "1 year-ahead consumer> # price index" as simply the log of the  
> price ratio between now and next> # year's observation> > inf <-  
> log(uscpi$usdcpi2000[2:ss]/uscpi$usdcpi2000[1:(ss-1)])> > # You can  
> take a look at the data with the following code> > plot(uscpi 
> $year[2:ss],inf,type="b",ylim=c(0,0.15))error in xy.coords(x, y,  
> xlabel, ylabel, log) :   'x' and 'y' lengths differ
>
> Could you please tell me what's wrong with it? I have attached my  
> data in this assignment.
> Thank you very much
> Best regards 		 	   		
> _________________________________________________________________

David Winsemius, MD
West Hartford, CT



More information about the R-help mailing list