[R] Extracting values from an array

Met Man crescenti at comcast.net
Fri Apr 27 05:49:31 CEST 2007

I have an array with dimension of 5001 (rows) by 40 (columns).  This array is
a series of power output from a wind turbine in kW.  The rows correspond to
wind speed from 0 to 50 m/s in 0.01 m/s step increments.  The columns
correspond to the air density values from 0.90 to 1.30 kg/m3 in 0.01 kg/m3
step increments.  I have a vector of wind speed and air density observations
(typically 8760 records for a year).  Given the wind speed and air density,
I want to select the proper wind turbine power output.  I've been trying to
figure this out, but am having a major brain fart.  I can do this in a for (
i in 1 : N  ) { } loop, but that is very, very inefficient.  Can anyone
suggest a simple, efficient way to do this in R?  Thanks.

View this message in context: http://www.nabble.com/Extracting-values-from-an-array-tf3655585.html#a10212795
Sent from the R help mailing list archive at Nabble.com.

More information about the R-help mailing list