[R-sig-eco] How to standardize data to a fixed range, such as [-1, 1]?
Will Morris
wkmor1 at gmail.com
Fri Jan 1 13:52:57 CET 2010
How bout,
If you data is x...
(((x - min(x))/max(x))*2)-1
Will Morris
Masters of Philosophy candidate
Vesk Plant Ecology Lab
The School of Botany
The University of Melbourne
Australia
Phone: +61 3 8344 0120
http://www.botany.unimelb.edu.au/vesk/
On 01/01/2010, at 22:22, Zongshan Li <zongshan_li at yahoo.com> wrote:
> Dear the friends of R-Ecology:
> I am a beginner for R language, and I think this problem might
> be some kind of stupid one.
> ---------------------
> My question is tostandardize the vectors of some dataset into the
> same range(such as[-1,1]), so as to plot these vectors into same X_Y
> axes and compare their fluctuations easily.
> ---------------------
> I try to use the functions: dnorm, pnorm, qnorm, but have the
> wrong results.
> I try to apropos("norm") and found no related function specific
> for standardizing data.
>
>
> Any help is strongly appreciated,
> thank you in advance,
>
> ----------------------
> Zongshan, Li
> 2010-01-01Research Center for Eco-Environmental Sciences,Chinese
> Academy of Sciences
> Shuangqing Road, Haidian street, Beijing, 100085
> Tel: 86-10-13699145748
> QQ: 1141958023
> email: ZongShan_Li at yahoo.com
> website: http://www.rcees.ac.cn/
>
>
>
> [[alternative HTML version deleted]]
>
> _______________________________________________
> R-sig-ecology mailing list
> R-sig-ecology at r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-sig-ecology
More information about the R-sig-ecology
mailing list