Try this:
LinePlot(1,1)
LinePlot=function(a,b){
+ # a = slope
+ # b = y intercept
+ x=seq(-10,10,0.4)
+ y=a*x+b
+ plot(x,y, type=l)
+ title(paste(a=,a,b=,b))
+ }
#test
LinePlot(a=-2,b=9)
HTH
--
View this message in context:
Hi,
I have a huge dataset (53 million records). I have to calculate the p and q
values of my data. How can I do it in R or perl? I have downloaded R (I'm
completely new to R). and the package qvalue but I don't understand how can
I call/use qvalue package with R. When I type library(qvalue), it
Sorry for possible misunderstanding:
I want to define a matrix (B) based on an existing matrix (A) in a single
step and keep A unchanged:
#Existing matrix
A=matrix(1:16,ncol=4)
A
[,1] [,2] [,3] [,4]
[1,]159 13
[2,]26 10 14
[3,]37 11 15
[4,]4
Thanks! But how could I find out their names on Amazon EC2?
--
View this message in context:
http://r.789695.n4.nabble.com/Looking-for-an-image-R-64-bit-on-Linux-64-bit-on-Amazon-EC2-tp2338938p2357731.html
Sent from the R help mailing list archive at Nabble.com.
Is this sufficiently single steppish for you?
D - A - matrix(1:16, 4)
D[3, ] - 2 * D[1, ] + D[3, ]
# Alternately, you could do this
# but it is much messier, and I do not see how
# two steps is really an issue
# you want to end up with two matrices anyways
# so it's not like you save memory by
On Fri, 2010-08-27 at 22:14 -0700, Stephen Liu wrote:
Hi Gavin,
Thanks for your advice and the examples explaining plotting settings.
The steps on your examples work on my test.
2) Don't attach() things, you are asking for trouble
If a function has a formula method (which plot
On 08/28/2010 03:10 AM, ndar wrote:
Hi,
I have a huge dataset (53 million records). I have to calculate the p and q
values of my data. How can I do it in R or perl? I have downloaded R (I'm
completely new to R). and the package qvalue but I don't understand how can
I call/use qvalue package
Matrix operations work the other way to what you expect on rows and
columns. Try
## Your data:
time - c(1, 2, 3) # Please don't use `t' as a variable name
cash_flow - c(7, 7, 107)
zero_rate - data.frame(rating=factor(c(AAA,AA,A,B)),
year1=c(3.60, 3.65, 3.72, 4.10),
On Aug 28, 2010, at 2:54 AM, Joshua Wiley wrote:
Is this sufficiently single steppish for you?
D - A - matrix(1:16, 4)
D[3, ] - 2 * D[1, ] + D[3, ]
# Alternately, you could do this
# but it is much messier, and I do not see how
# two steps is really an issue
# you want to end up with two
Hy,
I had a mistake on a function of a package i have created!
I have solved it and then i repackaged and installed the modified package.
I use to launch R from Excel!
And so when i launch R, and next call my function from the workspace, i
still find the problem on my function.
And when i read on
Hi:
Here are some functions for computing elementary matrices so that you can do
Gauss elimination the hard way (the easy way is the LU decomposition, but I
digress) I wouldn't use these for serious work, since there are no
checks for matrix instability, but the essential ideas are there. It
I have a large amount of data read in from over 140 excel files in the
format of x. r1 to r5 are repeat measures for a given Wavelength and
ANWC_NO.
I need to rearrange x into 3 columns, ANWC_NO,Wavelegth, value ie
ANWC_NOWavelength r1
ANWC_NOWavelength,r2
ANWC_NO
On Sat, Aug 28, 2010 at 1:32 AM, Cheng Peng cp...@usm.maine.edu wrote:
Sorry for possible misunderstanding:
I want to define a matrix (B) based on an existing matrix (A) in a single
step and keep A unchanged:
#Existing matrix
A=matrix(1:16,ncol=4)
A
[,1] [,2] [,3] [,4]
[1,] 1
On 28-Aug-10 11:27:30, Gabor Grothendieck wrote:
On Sat, Aug 28, 2010 at 1:32 AM, Cheng Peng cp...@usm.maine.edu
wrote:
Sorry for possible misunderstanding:
I want to define a matrix (B) based on an existing matrix (A) in a
single
step and keep A unchanged:
#Existing matrix
Hi Gavin,
Lot of thank for your detail explanation.
Just looked at;
?with
?within
Both Evaluate an Expression in a Data Environment
Usage: Both;
with(data, expr, ...)
within(data, expr, ...)
Details:
.
‘within’ is similar, except that it examines the environment after
Thank all help help. Ted's intuitive single step definition is what I want.
I try to teach elementary Linear Algebra using R to manupilate matrices.
Since my students have no programming experience at all, any fancy and
muliple step definition in matrix row operation will confuse them. Again, I
Dear David Sir,
Thanks a lot for your guidance. You reply besides helping, also taught me the
importance of sharing your knowledge. It also helped me understand where do I
stand. I am a starter in R and I have started going through at least some mails
everyday whenever possible so that I can
On 28-Aug-10 13:15:47, Cuckovic Paik wrote:
Thank all help help. Ted's intuitive single step definition
is what I want.
I try to teach elementary Linear Algebra using R to manupilate
matrices.
Since my students have no programming experience at all, any fancy and
muliple step definition in
I would like to fit a nonlinear model with nlme.
The model is a nonlinear growth model with five time points: y = X*b +
e, where design matrix X is defined as
X= | 1 0 |
| 1 1 |
| 1 k |
| 1 2k |
| 1 3k |
and parameter vector b = (b0, b1). And where k is a
On Aug 28, 2010, at 10:12 AM, (Ted Harding) wrote:
On 28-Aug-10 13:15:47, Cuckovic Paik wrote:
Thank all help help. Ted's intuitive single step definition
is what I want.
I try to teach elementary Linear Algebra using R to manupilate
matrices.
Since my students have no programming experience
On Aug 28, 2010, at 6:07 AM, Nevil Amos wrote:
I have a large amount of data read in from over 140 excel files in
the format of x. r1 to r5 are repeat measures for a given
Wavelength and ANWC_NO.
I need to rearrange x into 3 columns, ANWC_NO,Wavelegth, value ie
ANWC_NOWavelength
Thank you very much, David;
for row swapping: R2==R3
A=diag(1:4)
A
[,1] [,2] [,3] [,4]
[1,]1000
[2,]0200
[3,]0030
[4,]0004
A1=A[c(1,3,2,4),]
A1
[,1] [,2] [,3] [,4]
[1,]1000
[2,]0030
[3,]
Hi,
I am traying to implement an STAR model, but I have some problems.
I am following the instruction of the model, that they are in:
http://bm2.genes.nig.ac.jp/RGM2/R_current/library/tsDyn/man/star.html
that they are from:
http://bm2.genes.nig.ac.jp/RGM2/pkg.php?p=tsDyn
The model is:
I would like to fit a nonlinear model with nlme.
The model is a nonlinear growth model with five time points: y = X*b +
e, where design matrix X is defined as
X= | 1 0 |
| 1 1 |
| 1 k |
| 1 2k |
| 1 3k |
and parameter vector b = (b0, b1). And where k is a
For the record: lattice behaves slightly differently, it requires an
as.expression with bquote.
Dieter
plotExp - function(what) {
plot.new()
lab = bquote(Estimated~t[50]~ from ~.(what) ) ;
text(0.5,0.2,lab)
}
plotExp(tgv)
library(lattice)
plotLattice - function(what) {
lab =
On Aug 28, 2010, at 11:32 AM, Cuckovic Paik wrote:
Thank you very much, David;
for row swapping: R2==R3
A=diag(1:4)
A
[,1] [,2] [,3] [,4]
[1,]1000
[2,]0200
[3,]0030
[4,]0004
A1=A[c(1,3,2,4),]
A1
[,1] [,2] [,3] [,4]
On Aug 28, 2010, at 9:15 AM, Stephen Liu wrote:
Hi Gavin,
Lot of thank for your detail explanation.
Just looked at;
?with
?within
Both Evaluate an Expression in a Data Environment
Usage: Both;
with(data, expr, ...)
within(data, expr, ...)
Details:
.
‘within’ is similar,
On Aug 28, 2010, at 11:31 AM, David Winsemius wrote:
On Aug 28, 2010, at 6:07 AM, Nevil Amos wrote:
I have a large amount of data read in from over 140 excel files in
the format of x. r1 to r5 are repeat measures for a given
Wavelength and ANWC_NO.
I need to rearrange x into 3
Gavin gave some problems with relying attaching data, here is another example,
somewhat artificial, but not unrealistic (I had similar to this happen to me
before I learned better):
attach(women)
# do some stuff
library(lattice)
attach(singer)
# do some more stuff
# now we want to go back and
The following code shows that the unlisted data frame assigns an index to
each member. When one sorts the data frame based on ULST, he in fact uses
the (implicit) indices of ULST but not the actual values! Therefore, your
guess is correct.
test.vec=data.frame(c(A,F,C))
ULST=unlist(test.vec)
michael tufemichael at gmail.com writes:
C:\Users\FAN'S~1\AppData\Local\Temp\tpe2b4012b_f9ed_402d_af0f_f21ebd8116a6.mat
-V6 B
I bet the problem is with the single quote (') in the path.
__
R-help@r-project.org mailing list
Bert Gunter gunter.berton at gene.com writes:
John:
1. As always, and as requested (see posting guide), a small
reproducible example might help.
Bert is right that things aren't well defined. However, AIC
is still *widely* used for nonlinear models. For the sloppy
folks among us, here
Hello!
I need some help.
How I know it to draw the formula of the binomial distribution?
expr-expression(P(xi == k) == choose(n, k)* p^k*(1-p)^(n-k)) --- not good
on the screen the choose(n, k) not the Binomial Formula, but choose(n,
k)
Thanx!
[[alternative HTML version deleted]]
Hi.
On Fri, Aug 27, 2010 at 7:08 PM, michael tufemich...@gmail.com wrote:
Henrik,
The line before that is:
Received cmd: 2
save
C:\Users\FAN'S~1\AppData\Local\Temp\tpe2b4012b_f9ed_402d_af0f_f21ebd8116a6.mat
-V6 B
You should see have seen something like:
save(tmpname, '-V6', 'B');
try:
?pbinom
--
View this message in context:
http://r.789695.n4.nabble.com/binomial-distribution-tp2398568p2398705.html
Sent from the R help mailing list archive at Nabble.com.
__
R-help@r-project.org mailing list
On 08/28/2010 10:23 PM, tamas barjak wrote:
Hello!
I need some help.
How I know it to draw the formula of the binomial distribution?
expr-expression(P(xi == k) == choose(n, k)* p^k*(1-p)^(n-k)) --- not good
on the screen the choose(n, k) not the Binomial Formula, but choose(n,
k)
My function is like this
sim.res-gaussian_simulation(p=3, r=4, q=3, c=0.1,d=2,
Wchoice = avg,
pre.scaling = TRUE,
oos = TRUE,
alpha = NULL,
n = 100, m = 100, nmc = 100)
which is defined as
gaussian_simulation - function(p, r, q, c,
d =
Henrik,
Yes I replaced the MatlabServer.m and restarted Matlab and R, it seems the
problem is still there. I see save(temp,-v6,B) there too. I use
MatlabServer.m mannually in Matlab, actually I couldn't use it in R, Matlab
will pop up a command window and never respond.
Thanks,
Michael
On Aug 28, 2010, at 4:48 PM, Sancar Adali wrote:
My function is like this
sim.res-gaussian_simulation(p=3, r=4, q=3, c=0.1,d=2,
Wchoice = avg,
pre.scaling = TRUE,
oos = TRUE,
alpha = NULL,
n = 100, m = 100, nmc = 100)
which is defined as
gaussian_simulation - function(p, r,
Michael,
could you please give me *verbatim* details on what messages you are
seeing. In your previous reply you did *not* report seeing
save(tmpname, '-V6', 'B'); and now you say you get it. Please do
not abbreviate what you are getting (e.g. save(temp,-v6,B)), because
that will not be useful
Hi,
Suppose I have a dataframe like:
data
yx
1 1 2008
2 1 2008
3 0 2008
4 0 2009
5 1 2009
Now I want to know how much 1 corresponds with 2008 and how much with
2009, the answers are 3 and 1.
How can I achieve this? Thanks for the anwer.
André
I would like to fit a nonlinear model with nlme.
The model is a nonlinear growth model with five time points: y = X*b +
e, where design matrix X is defined as
X= | 1 0 |
| 1 1 |
| 1 k |
| 1 2k |
| 1 3k |
and parameter vector b = (b0, b1). And where k is a parameter to
Perfect!
Thank You!
2010/8/28 Peter Dalgaard pda...@gmail.com
On 08/28/2010 10:23 PM, tamas barjak wrote:
Hello!
I need some help.
How I know it to draw the formula of the binomial distribution?
expr-expression(P(xi == k) == choose(n, k)* p^k*(1-p)^(n-k)) --- not
good
on the
See
?table
for details.
tmp - ' yx
+ 1 1 2008
+ 2 1 2008
+ 3 0 2008
+ 4 0 2009
+ 5 1 2009'
data - read.table(textConnection(tmp), header=TRUE)
data
yx
1 1 2008
2 1 2008
3 0 2008
4 0 2009
5 1 2009
table(data$x, data$y)
0 1
2008 1 2
2009 1
Hi,
Can anybody show me how to extract all columns in my dataset that are
polymorphic? Or phrased in another way I would like to delete all
columns that have no more than one letter in it (that are monomorphic).
Thank you.
Laetitia
V1 V2 V3 V4 V5 V6 V7 V8 V9 V10 V11 V12 V13 V14
V15 V16
Wow. That was fast. And it works. Thank you!
Laetitia
Am 29.08.2010 um 00:35 schrieb Jorge Ivan Velez:
index - apply(d, 2, function(x) length(table(x)) 1)
d[, index]
[[alternative HTML version deleted]]
__
R-help@r-project.org mailing
On Aug 28, 2010, at 1:24 PM, Laetitia Schmid wrote:
Hi,
Can anybody show me how to extract all columns in my dataset that
are polymorphic? Or phrased in another way I would like to delete
all columns that have no more than one letter in it (that are
monomorphic).
Assuming you read this
Henrik,
OK, finally I got the problem: I have an apostrophe in my
windowns 7 user name. That mess up the file name. So I logged in using a
guest account and it works:
Received cmd: 1
eval string: B
B =
-0.1347
Sent byte: 0
Received cmd: 1
eval string: variables = {'B'};
Sent byte:
OK, I think it is just B[1].
Thanks!
Michael
On Sat, Aug 28, 2010 at 6:50 PM, michael tufemich...@gmail.com wrote:
Henrik,
OK, finally I got the problem: I have an apostrophe in my
windowns 7 user name. That mess up the file name. So I logged in using a
guest account and it
Greetings,
I use maxNR function under maxLik package to find the REML estimates of the
parameters of variance components in heteroskedastic linear regression models.
I assume that in the model there is additive/multiplicative/mixed
heteroskedasticity and I need estimate the
Christopher David Desjardins desja004 at umn.edu writes:
Hi,
I am running a Cox Mixed Effects Hazard model using the library coxme. I
am trying to model time to onset (age_sym1) of thought problems (e.g.
hearing voices) (sym1). As I have siblings in my dataset, I have
decided to
Hi.
On Sat, Aug 28, 2010 at 3:50 PM, michael tufemich...@gmail.com wrote:
Henrik,
OK, finally I got the problem: I have an apostrophe in my
windowns 7 user name. That mess up the file name. So I logged in using a
guest account and it works:
Received cmd: 1
eval string: B
B =
On Aug 27, 2010, at 4:32 PM, Teresa Iglesias wrote:
Christopher David Desjardins desja004 at umn.edu writes:
Hi,
I am running a Cox Mixed Effects Hazard model using the library
coxme. I
am trying to model time to onset (age_sym1) of thought problems (e.g.
hearing voices) (sym1). As I
Dear R People:
I just produced the following:
x - seq(-3,3,.01)
x[x= -0.50 x= -1.0]
numeric(0)
x[x= -0.50 x= -1.0]
numeric(0)
What am I doing wrong, please? This seems strange.
Thanks,
Erin
--
Erin Hodgess
Associate Professor
Department of Computer and Mathematical Sciences
University
Sorry.
--
Erin Hodgess
Associate Professor
Department of Computer and Mathematical Sciences
University of Houston - Downtown
mailto: erinm.hodg...@gmail.com
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do
Dear Erin,
-0.50 is greater than -1.00, this means that your logical test returns
all FALSE answers. Now consider the results of:
x[FALSE]
you are selecting none of 'x', hence numeric(0).
Perhaps you mean:
x[x = -0.50 x = -1.0]
HTH,
Josh
On Sat, Aug 28, 2010 at 7:47 PM, Erin Hodgess
On Sat, Aug 28, 2010 at 8:38 PM, David Winsemius dwinsem...@comcast.netwrote:
On Aug 27, 2010, at 4:32 PM, Teresa Iglesias wrote:
Christopher David Desjardins desja004 at umn.edu writes:
Hi,
I am running a Cox Mixed Effects Hazard model using the library coxme. I
am trying to model time
57 matches
Mail list logo