[R] problems with loess

From: Dimitri Giunchi <dgiunchi_at_discau.unipi.it>
Date: Sat 08 Oct 2005 - 01:48:44 EST


Hi all,

I was unable to obtained a smoothed line using the loess function. I used the following code reported in the examples of R documentation:

cars.lo <- loess(dist ~ speed, cars)

Then I tried to plot both the data and the smoothed line

plot(cars)
lines(cars.lo)

but what I obtained is simply a broken line joining all the data points. I tried with different spans, but the results did not change.

Does anyone know what's going wrong?

Thanks

Dimitri

platform i386-pc-mingw32

arch     i386           
os       mingw32        
system   i386, mingw32  
status                  
major    2              

minor 2.0

--
Dimitri Giunchi
Dipartimento di Etologia Ecologia Evoluzione Università di Pisa
Via A. Volta 6
56126 Pisa
ITALY
Tel: +39 050 2219036
Fax: +39 050 24653



R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Received on Sat Oct 08 02:06:27 2005

This archive was generated by hypermail 2.1.8 : Fri 03 Mar 2006 - 03:40:38 EST