year1 is the time series data set below
11.64
11.50
11.49
11.16
11.15
11.37
11.37
11.57
11.83
11.87
11.85
11.92
11.77
11.71
11.57
11.24
11.27
11.33
11.17
.
With a total of 1304 rows of data.
When I try to run the code:
diff(sqrt(year10))
I get the response: "data frame with 0 col
I think I figured it out...The 2 data sets must have same number of data.
--
View this message in context:
http://r.789695.n4.nabble.com/Help-regarding-Time-Series-CCF-Function-tp2992988p2993061.html
Sent from the R help mailing list archive at Nabble.com.
Looking at 2 sets of time series data. Code below:
> houst = read.table("C:/Documents/HOUST.txt",header=F)
> houst = ts(houst, start = 1976,frequency = 12)
> mortg = read.table("C:/Documents/mortg.txt",header=F)
> mortg = ts(mortg, start = 1976,frequency = 12)
The data for houst looks like:
1367
Sorry about that. Still new to this... The code below should be
reproducible.All R2 should just be 1, and I should write 1 to
R2outputKKNN.txt 10 timesnothing is happening. Appreciate the efforts
to help!
for (i in 1:10)
{
adata = 1:5
bdata = 6:10
lm <- lm(adata
iterations <- 100
nvars <- 4
combined <- rbind(scaleMiceTrain, scaleMiceTest)
reducedSample <- combined
reducedSample <- subset(reducedSample, select = -pID50)
reducedSample <- subset(reducedSample, select = -id)
for (i in 1:iterations)
{
miceSample <- sample(combined[,-c(1,2)],nvars, repl
names(miceTrainSample)
[1] "b_double" "KierA2""KierFlex" "Q_VSA_POS" "pID50"
In the above code, how do I delete "pID50" column to store the resulting
object without indicating column "5". The code below does the trick, but I
wish to delete the column by specifying "-pID50" instead of "5".
The data set for "combined" is pretty huge, but a few columns looks like
this, so just picture it with 187 columns:
dw_area vdw_vol vsa_acc vsa_acid vsa_base vsa_donvsa_hyd
1 0.8322680 0.93714800 -0.478551 -0.2791860 -0.724420 1.4647400
2 1.8746300 1.2639 0.23148
But "miceSample" has multiple columns... For example if nvars=4, I have 4
columns of data to delete from "combined".
Specifically, I have 187 columns in "combined", and "miceSample" only has 4
columns. So the new data frame should have 183 columns.
--
View this message in context:
http://r
e.g. I have a big data set called "combined", and then a small sample of
"combined" called "miceSample". I wish to delete "miceSample" from
"combined" to create a new smaller data set and store it into a new object.
combined <- rbind(scaleMiceTrain, scaleMiceTest)
miceSample <- sample(combined[
I combined 2 data frames together using rbind... How do I unbind the data at
a specific row to create 2 separate data frames?
--
View this message in context:
http://r.789695.n4.nabble.com/What-is-the-opposite-of-rbind-tp2289244p2289244.html
Sent from the R help mailing list archive at Nabble
Maybe I'm missing something, but after reading the reshape package, I'm still
not quite sure how reshaping the data will help me with storing the
previously used samples and preventing me from selecting previously used
samples in the future.
This is my pseudo code thought process, but I'm not s
Sorry to post multiple questions, but this is still related to the sample
function.
In my previous example, how do I save/store the current sample so when I run
sample again (after analysis) I can exclude the samples that were previously
chosen.
For example if I have 180 factors or columns...an
id pID50 apol a_acca_acid a_aro a_base a_count
1 mol.11 3.63 -0.882267 -0.527967 -0.298197 -1.032380 0 -1.063410
2 mol.14 3.38 -1.007330 -0.527967 -0.298197 -1.032380 0 -1.063410
3 mol.19 3.18 1.153560 1.407910 -0.298197 1.254100 0 1.160080
4 mol.20
For example: When I take a sample of 5 from 10 columns, I want to exclude
from the sample column 1 from being chosen. How do I do this?
--
View this message in context:
http://r.789695.n4.nabble.com/Want-to-exclude-a-column-when-using-sample-function-tp2287988p2287988.html
Sent from the R h
I figured out the answer. Since I have both the predicted and actual values,
I simply need to call the lm function, and summary to see R^2 which matches
what MOE provided.
myline.fit <-lm( y~x)
summary(myline.fit)
--
View this message in context:
http://r.789695.n4.nabble.com/R2-function-fro
Hopefully simple question: What is the best way to name, and treat factor
columns for data that has lots of columns?
This is my column list:
id pID50 D.1 D.2 D.3 D.4 D.5 , etc. all the way to D.185
I was under the impression from several R examples in pls that if you name
your columns like ab
Hello, I have tried multiple times to unsubscribe from the general
mailing list to no avail. I only wish to receive emails when someone
posts a response in my thread. How do I do this? Thanks.
--
- Addi
__
R-help@r-project.org mailing list
https:/
Hello,
I am having some trouble using a model I created from plsr (of train) to
analyze each invididual R^2 of the 10 components against the test data. For
example:
mice1 <- plsr(response ~factors, ncomp=10 data=MiceTrain)
R2(mice1)##this provides the correct R2 for the Train data for 1
18 matches
Mail list logo