Displaying 20 results from an estimated 300 matches similar to: "Saving a variable"
2012 May 10
1
Error t value matrix
Hi all,
I want to make the following:
I want to run a linear regression on each column of a matrix "estima" on
the correspondent column on the matrix "estima2".
You see I want to regress estima[,1] on estima2[,1] this way to all
columns....
At the same time I want to make a regression adding each time a new
observation.
You see, the first regression will regress only one
2012 May 05
2
No error message no display output
Hi all,
I´m re-starting (as my name indicates) my little knowlegde of CRAN R.
I made this function time before but I don´t know where is the error
because nothing appears as an error but the histogram plot doesn´t appear.
Should I install some special library to run sapply?
pru<-function(){
randz<-matrix(rnorm(200000),100,2000)
H<-matrix(0,100,2000)
for (j in 2:2000){
for (i in
2009 Jul 16
3
rnorm
Hi I want to simulate random numbers normal distributed with this size
(2000,10000).
I tried this but my computer exhaust there is a fast way to make it?
randz<-matrix(rnorm(2000000),2000,10000)
[[alternative HTML version deleted]]
2009 Jul 21
3
writte file doubt
Hi I wrotte this function but when I get the "tmp.xls" file it shows data
in a rare way. I mean not appears a matrix with 2000 rows and 100 columns.
Can anyone help me, guide me?
kim<-function(){
tmp<-randz<-matrix(rnorm(200000, mean=0,sd=0.01 ),2000,100);
dim(tmp)
write(tmp,file="tmp.xls")
Thanks in advance.
On the other hand, everytime I execute a function
2012 Jun 09
1
Inf and NA
Hi all,
I have a csv matrix "KT.csv" and it has Inf and NA
I want to calculate the mean of each row so I use
rowMeans(KT,na.rm = TRUE) but with this Inf cannot be omminted.
I?m trying to use before running rowMeans(KT,na.rm = TRUE)
KT<-range(KT,finite=TRUE)
but it doesn?t works...
Do you know a simple way to ommit Inf en the calculations?
Many thanks.
I have tried also to
2011 Jun 27
2
Executing the same function on consecutive files
Hi all,
I have the next problem: I have a matrix with size 8,000,000x18. My personal
computer...blocks...so I have cut my original file into 100 different file.
I have written a function that should be run on each of this file.
So imagine
I need to read data from q1 to q100 file
data<-read.table("q1.txt",sep="")
and each time I read 1 file execute my personal function
2010 Mar 23
2
Creating pdfs using qplot in qqplot2
I am trying to create plots within a for loop and output them to a pdf.
Here is a working example using plot:
gg <- data.frame(datadate=1:4, spread=5:8)
pdf()
for (i in 1:3) {
plot(gg$datadate, gg$spread, main=i)
}
dev.off()
I am trying to learn more about ggplot2 so I try a slight modification
and it doesn't work. Anyone
2012 Feb 28
3
Database
Hi all,
I´m new using Access. I see that many things that you can do on Access you
can do on CRAN R but not on contrary.
My question is: Is there any manual with examples comparing how to do data
base analysis on access and making the same on CRAN R?
Imagine I want to compare two columns "Name" of two different data bases. I
want to see if there are "identical" names on both
2013 Apr 01
2
plot
Hi all if I plot a graph on R, I press on the plot Export/Save Plot as
Image....
I change name on "File name:"
I select Directory....Bibliotecas\Documentos
And select Width 800 and Height 800
And finally save in format JPEG
It is posible to "type" code so that I can run my function and it is not
necessary to make it manually?
Thanks in advance.
[[alternative HTML
2012 May 05
2
Editor to program with CRAN R
Hi all,
I´m using the windows writting pad (not Notepad the simplest version). I
think there should be greater and helping note pads to help programming.
Can you suggest one?
Many thanks¡¡¡¡
[[alternative HTML version deleted]]
2012 Jul 17
2
order or sort doesn´t work properly
Hi all,
I want to order a series that is included on the second column in MCT.csv.
I do but R doesn?t order, could be because is a csv?
I have prove
MCT<-read.csv("MCT.csv")
a<-order(MCTor[,2],2,decreasing = FALSE)
a<-order(MCTor[,2],1,decreasing = FALSE)
or the same with sort but didn?t worked.
It is suposed that a will have the ordered on ascending or descending
2011 Jun 09
1
Item analysis
Hi all,
For several reasons I have no used CARN R in months....I have an idea and I
want to retry to learn CRAN R.
I know I need to formulate more "intelligent" questions but I will expose
and if someone can help me I would be very gratefull I promise to try to
learn again....
The question I have a data file like this:
Date, Time, Tip
13/11/2008,23:16:00,432
13/01/2009,23:17:00,633
2012 May 06
3
PLot a matrix
Hi,
I want to plot this matrix (I attach the data), it is suposed that each
column is a different time series.
If I do
g<-read.table("dataADF.txt", header=F)
and
plot(g[,1],type="l")
it plots the first column plot if I want in a unique graph each colums of
dataA, all in one. How should I proceed?There is a direct pre-defined code?
And If I wanted a plot by each
2011 Jun 29
2
Executing a script "hand-made" and time
Hi all,
I have a function written by me that read a matrix (data frame) from a txt
with 4 million of rows and 13 columns.
The think is my function works with an input matrix of 100x13 and now I
tried to execute my function with the big "input file" and it is running
form the moment two hours...
There is a way to know (how much time could it cost?)
The second question is...
I want
2011 Jul 02
5
How many times occurs
Hi all,
I have a data matrix likein "input.txt"
8 9 2 5 4 5 8 5 6 6
8 9 2 8 9 2 8 9 2 1
8 9 2 5 4 5 8 5 6 4
8 9 2 5 4 5 8 5 6 6
8 9 2 8 9 2 8 9 2 1
8 9 2 5 4 5 8 9 2 2
In this example will be an 6x10 matrix (or data frame)
I want to detect how many times in a row appears this combination 8 follewd
by 9 followed by 2, and create a new matrix with only this number of occurs
then
2011 Jun 28
4
Separator of data
Hi all,
I have a matrix like this:
188556644
225588666
558888555
I try to read the table using read table but if I put sep="" I have seen it
expects a white space, is there a "sep" option to read this matrix so
each single number is a position of the matrix
You see this matrix would be an 3x9 matrix
I tried other option but also didn´t worked.
If sep = "" (the
2011 Dec 14
1
Hi
First PRoblem solved
> read.csv("KT80.csv")
X x
1 1 0.01331361
>
I ommitt "" in calling the file name...
2011/12/14 Trying To learn again <tryingtolearnagain@gmail.com>
> Hi all,
>
> I have 100 csv files always with this information (I Attach two example
> excels)
>
> KT80.csv contains:
> ,"x"
>
2012 Aug 04
4
DAtes
Hi all,
I´m trying to convert as a data frame (with format "date") this copied
excel column of dates (exposed below), I have tried to save them in a txt
file
tfr<-read.table("tfra.txt")
tfr<-data.frame(tfr)
I have tried several things, as date, so on, but always error.
And it makes
Error en as.Date.default(tfr, "%m/%d/%y") :
do not know how to convert
2011 Jan 12
2
aggredating date data
I tried a date by date forecast of a time series and it seems to be
too wild. How can I aggregate the date into weeks or months as
required?
Thanks.
The input looks like
ID datadate("YYYY-MM-DD") value_for_day
-- ----- -------
-- ------ --------
and I want to be able to change it to
ID dataweek value_for_week
or
2013 Apr 08
1
Tablet and executing R
Hi all,
Have any of you instaled R on a Tablet, in this case, which Tablet. My
family wants me to gift a Tablet but I suposse R can not be instaled on a
Tablet. And my few "free" time I pass mainly trying to "improve" in R.
Can yoy tell me, if there are, wich Tablets should be instaled?
[[alternative HTML version deleted]]