All,

Trying to avoid using attach and detach while teaching class in Intro Stats.
data=read.delim("dataset1.dat",header=TRUE)
with(data,{
  sort(age)
  length(age)
  (age[10]+age[11])/2
})

However, this code only produces output for the last line between the curly
braces. Granted, as we type the lines in one at a time and execute the code,
we'll see each output. And, we can fix the problem by adding a print to each
line.

Wonder if there are any other suggestions?

David



--
View this message in context: 
http://r.789695.n4.nabble.com/With-question-tp4676379.html
Sent from the R help mailing list archive at Nabble.com.

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to