Displaying 20 results from an estimated 5000 matches similar to: "how to get growth rate of a (time series) data?"
2012 Dec 20
5
an entry level (stupid) question
Hello all, i'm a newbie to R and now I get stuck by the question, would
anybody help me please?
Suppose, I got the following
> test <- data.frame(test1=c(c(0.00, 0.005, 0.01, 0.015, 0.02)))
> test
test1
1 0.000
2 0.005
3 0.010
4 0.015
5 0.020
Now I want another column inside test, named test2
for i=c(1:5), If test$test1[i] is 0, then the value of test$test2[i] is
1/test1[i]
or
2009 Oct 08
3
I can not install DAAG package . help
I use R on my Ubuntu 9.04 laptop, which was installed by "aptitude install"
way
Now i'm learning a book of R which needs "MASS" and "DAAG" installed.
So i followed the instructions:
>install.packages("MASS")
>library("MASS")
MASS works fine.
But DAAG doesn't. Anyone who could help would be appreciated a lot !
Below are my error
2009 Oct 08
3
I can not install DAAG package . help
I use R on my Ubuntu 9.04 laptop, which was installed by "aptitude install"
way
Now i'm learning a book of R which needs "MASS" and "DAAG" installed.
So i followed the instructions:
>install.packages("MASS")
>library("MASS")
MASS works fine.
But DAAG doesn't. Anyone who could help would be appreciated a lot !
Below are my error
2008 Sep 02
1
installation problem: package 'mgcv' could not be loaded
Hello all, i'm a newbie of R trying to make some statistical work in R
environment. Now i have to laptops, one is Thinkpad X40 with Debian
Lenny and the other is Thinkpad T43 with Ubuntu 8.10. Recently i met
such problem and am wondering if anybody can do some help.
After upgrading my /etc/apt/sources.list , i install R by apt-get
install command. It works fine in both laptops. Then i
2008 Sep 02
1
installation problem: package 'mgcv' could not be loaded
Hello all, i'm a newbie of R trying to make some statistical work in R
environment. Now i have to laptops, one is Thinkpad X40 with Debian
Lenny and the other is Thinkpad T43 with Ubuntu 8.10. Recently i met
such problem and am wondering if anybody can do some help.
After upgrading my /etc/apt/sources.list , i install R by apt-get
install command. It works fine in both laptops. Then i
2010 Nov 10
2
Parallel code runs slower!
My parallel code is running slower than my non-parallel code! Can someone
pls advise what am I doing wrong here?
t and tTA are simple matrices of equal dimensions.
#NON PARALLEL CODE
nCols=ncol(t)
nRows=nrow(t)
tTA = matrix(nrow=nRows,ncol=nCols)
require(TTR)
system.time(
for (i in 1:nCols) {
x = t[,i]
xROC = ROC(x)
tTA[,i]=xROC
}
)
user system elapsed
123.24 0.07 123.47
#
2008 Jan 30
2
numeric coercion when one or more elements is non numerice
I don't understand this behavior. Why does the every data point get trashed by data.matrix when there is one non-numeric element in the array? Thanks.
> temp
GDP CPIYOY
19540 2098.1 garbage
19632 2085.4 0.9
19724 2052.5 0.8
19814 2042.4 1.1
> data.matrix(temp)
GDP CPIYOY
19540 4 4
19632 3 2
19724 2 1
19814 1
2004 Jun 23
2
Covered Labels
Dear All!
How can I cope with overlapping or covered labels (covered by labels
from other data points) in plots?
Martina Renninger
[[alternative HTML version deleted]]
2012 Apr 30
5
Different varable lengths
Hi!
I'm trying to do a lm() test on three objects. My problem is that R protests
and says that the variable lengths differ for one of the objects
(Sweden.GDP.gap). But I have double checked that the number of observations
are the same. All three objects should contain 9 observations but R only
accepts 9 observations in two of the objects. The third must have 10! Very
confusing because there
2013 May 28
3
[LLVMdev] unexpectedly loop hanging
Hello everyone,
I was able to get all the execution paths between 2 points (basic blocks)
in my program (with the condition to traverse a loop only once). I mapped
all the basic blocks to integers and created a correspondent directed graph.
I was able to get all the paths (a path is represented by an integer
identifier). For my target program I have 72 paths, but the program hangs
unexpectedly
2001 Sep 24
3
x axis point labels
I am attempting to manually specify x axis value labels (NOT x axis label as
in xlab) on a density plot. Generally speaking, I would like to erase the
default x axis point labels and replace them with arbitrary x axis point
labels relating to specific CDF points.
I am sure this can be done, but it isn't obvious to me how. Has anyone done
this before?
My R code follows if it helps (new
2004 Apr 14
3
A bug report?
Folks,
I have a strange situation, which I may have isolated as a bug
report. Or, it could just be that there's something about R that I
don't know. :-) I have attached the data file and the program file but
don't know whether these attachments will make it into the list. Here
is my bugreport.R program --
---------------------------------------------------------------------------
2013 May 28
0
[LLVMdev] unexpectedly loop hanging
As an update, it is a memory problem which I don't know how to fix.
I tried to skip the problematic piece of code when in the case when the
loop hangs. So I did something like :
if( instr )
{
LLVMContext& C = instr->getContext();
Value* values[cnt];
errs()<<"\ngy: \n";
if(!(desters==7)){ // this
2012 May 22
4
“For” calculation is so slow
Dear All,
The function I wrote can run well with the small data, but with the large
data, the function runs very very slowly. How can I correct it? Thank you
very much. My function as below:
a<-c(1:240)
b<-c(1:240)
l=function(a,b){
v=0
u=0
uv=0
v[1]=0
u[1]=0
uv[1]=0
for (i in 1:(length(s)-1)){
v[i]<-((gx[[i]][b,(gx[[i]][a,1]+1)])-(gx[[i]][a,gx[[i]][a,1]+1]))/(gx[[i]][a,gx[[i]][a,1]+1])
2013 May 28
1
[LLVMdev] unexpectedly loop hanging
Hi,
I don't know much about this issue, but this malloc error won't be solved
by a change to delete[] or free. In fact, if you use the incorrect one for
simple types, you may not notice it. The error you have seems to me like a
memory corruption because you went out of bound and corrupted the memory
somewhere, Valgrind may help you figure out what is going on.
Cheers,
Matthieu
2013 May 16
1
To List or Not To List
Dear R Helpers,
A few weeks ago I asked for some help on how to accomplish modifications
to data in a set of data frames. As part of that request I mentioned that
I realized that one way to accomplish my goal was to put the data frames
together in a list but that I was looking for a way to do it with data
frames and a loop because I "believe the better thing is to work df by df
for my
2011 Dec 07
1
removing specified length of text after a period in dataframe of char's
Dear all,
I'm trying to remove some text after the period (a decimal point) in
the data frame 'hi', below. This is one step in formatting a table. So
I would like e.g.
"2.0" to become "2"
and "5.3" to be "5.3",
where the variable digordered contains the number of digits after the
decimal that I would like to display, in the same order in which
2013 May 03
2
[LLVMdev] set of integers to metadata
Hello everyone,
I want to pass a set of integers using metadata but I don't know how. I
have tried:
the integers are in array[]
*1. *
LLVMContext& C = is->getContext();
Value* values[size];
for(int gy=0;gy<size;gy++){
values[gy]=ConstantInt::getSigned(Type::getInt64Ty(C),array[gy]);
}
*is->setMetadata("path",MDNode::get(C,values));*
failes when setMetadata(),
1999 Sep 11
1
legend(): adjust space between symbol and tex
Hello,
I'd like to ask, how to adjust the space between symbol/line and text in a
legend. My legend() is build like that
legend(xmax-netzdiff/11, # shouldn't matter here
ifelse(ydiff>=0, #
ymin-6.5*(netzdiff/11), #
ymax-netzdiff/11), #
c("stehender Stamm","Windwurf",
2009 Feb 01
5
Sending Calls via SIP trunk from two different IP addresses from same Asterisk Machine
Hi All;
I can assign for my Asterisk Machine a two IP addresses (xxx.xxx.xxx.yyy and xxx.xxx.xxx.yyz), how can I use these two IP's so I can let one call sent with a source IP address xxx.xxx.xxx.yyy and another call to be sent with another source IP address xxx.xxx.xxx.yyz, I need this because I need the side to authorize my calls by the IP address, and some calls to be authorized with the