Re: [R] create arrays

From: David Wolfskill <r_at_catwhisker.org>
Date: Fri, 06 May 2011 12:15:56 -0700

On Fri, May 06, 2011 at 12:11:30PM -0700, Schatzi wrote:
> In Matlab, an array can be created from 1 - 30 using the command similar to R
> which is 1:30. Then, to make the array step by 0.1 the command is 1:0.1:30
> which is 1, 1.1, 1.2,...,29.9,30. How can I do this in R?
> ...

This may well be a hack, but

> 10:300/10

seemed to do it for me.

Peace,
david

-- 
David H. Wolfskill				r_at_catwhisker.org
Depriving a girl or boy of an opportunity for education is evil.

See http://www.catwhisker.org/~david/publickey.gpg for my public key.

______________________________________________ R-help_at_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.

  • application/pgp-signature attachment: stored
Received on Fri 06 May 2011 - 19:19:34 GMT

This quarter's messages: by month, or sorted: [ by date ] [ by thread ] [ by subject ] [ by author ]

All messages

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Fri 06 May 2011 - 19:20:06 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive