See 'Writing R Extensions'
On Thu, 19 Jun 2008, Hua Li wrote:
Dear all,
I'm writing to check with you whether there is a way to create .exe
file(or something like that) with R. Now working on creating a program
to take inputs from users (with tcl/tk), I would appreciate any idea to
make the
On Thu, 19 Jun 2008, Bryan Hanson wrote:
Thanks so much to all who offered assistance. I have to say it would have
taken me a long time to figure this out, so I am most grateful. Plus,
studying your examples greatly improves my understanding.
As a follow up, the fit process gives the followin
Gundala Viswanath gmail.com> writes:
> I am trying to plot 100 x 100 matrix data in a level plot.
> The problem I have is that the x/y -axis label in ticks
> are jumbled together. Thus I want X/Y axis to contain
> 10 ticks only, yet still plotting all the 100 data.
>
> Is there a way to do it?
>
Dear all,
I have try to use mle() from package stats4 to estimate parameters of
the following model:
p = Pr(Y = 0) = C + (1 - C)F(x'\beta)
a probit model with natural response.
The log-likelihood function is:
fr <- function(c, alpha, beta) {
P <- c + (1-c) * pnorm(alpha + beta * x)
P <- pmax
Hi
I am trying to plot 100 x 100 matrix data in a level plot.
The problem I have is that the x/y -axis label in ticks
are jumbled together. Thus I want X/Y axis to contain
10 ticks only, yet still plotting all the 100 data.
Is there a way to do it?
The code I have below doesn't work.
__BEGIN__
I try to use a functional programming style. I define functions within
functions when it is helpful in terms of information hiding. I avoid
writing functions with side-effects as much as possible, so the only
communication of the called function with the caller function is through
the arguments and
Alfredo Alessandrini wrote:
> Hi,
>
> With this data.frame:
>
>
>> class(rwl)
>>
> [1] "data.frame"
>
>
>> rwl
>>
> 0028002F 0028013F 0028032F
> 1833 3.39 NA NA
> 1834 3.09 NA NA
> 1835 3.05 NA NA
> 1836 3.31 NA NA
>
On 20/06/2008, at 4:07 PM, Moshe Olshansky wrote:
If you know the value of k then you could do the following:
goodNames <- paste("V",1:k,sep="")
ind <- which(colnames(df) %in% goodNames)
df[,ind]
(where df is your dataframe).
P.S. I won't be surprised if df[,goodNames] is all right too (have
I am wondering if people on the list could recommend books that they
have found helpful about programming concepts and style? I often find
that students write R programs by copying existing code but could really
benefit from the understanding of more general programming ideas. An
example would
Hello all,
I need a package for an kernel discriminant analysis with multivariate
binary data.
Thanks.
a.suarez
--
View this message in context:
http://www.nabble.com/kernel-discriminant-analysis-with-binary-data-tp18021145p18021145.html
Sent from the R help mailing list archive at Nabble.com
If you know the value of k then you could do the following:
goodNames <- paste("V",1:k,sep="")
ind <- which(colnames(df) %in% goodNames)
df[,ind]
(where df is your dataframe).
P.S. I won't be surprised if df[,goodNames] is all right too (have not checked).
--- On Fri, 20/6/08, Gundala Viswanath
Hi,
Suppose I have the following data frame:
V1 V2 V3 var
1 100 200 400 2.3
2 40.5 1.2 20.3
...
In this example the maximum V column is 3.
In my code there the column number can be varied.
My question is how can I access data frame
from column V1 up to Vk (some "k" and excluding'var' column)
Hello there. I wanted to segment customers and is trying both kmeans and
HCA method in R.
As I don't know how many cluster is good for a set of data, in kmeans, I
tried the code below and get a nice plot on number of cluster vs SSE.
Looking at the slope between cluster number, I h
You can use the 'symbol' element in an expression. For example
plot(1:5)
text(2,3,expression(symbol("\xD1")))
S.
>>> "Nuno Prista" <[EMAIL PROTECTED]> 06/19/08 9:55 PM >>>
Dear colleagues,
Can anyone of you tell me how to write a "nabla" symbol in an R graph?
Thanks in advance,
N
On 19/06/2008 7:25 PM, dave gregovich wrote:
Hello,
My package has passed all the R CMD CHECK steps except one. There is an
object which I placed in a sysdata.rda file (located in the 'R' directory of
the source package). Even though users have no need to access this object,
which is a character
Thanks so much to all who offered assistance. I have to say it would have
taken me a long time to figure this out, so I am most grateful. Plus,
studying your examples greatly improves my understanding.
As a follow up, the fit process gives the following error:
Warning messages:
1: In eval(expr,
Hi Tyler,
> I've attached 100 rows of a data frame I am working with.
> I have one factor, id, with 27 levels. There are two columns of reference
> data, x and y (UTM coordinates), one column "date" in POSIXct format, and
> one column "diff" in times format (chron package).
>
> What I am trying t
Thanks. I think I've got it. However, the density is plotted, not the
frequency. Is there a way to convert the density back to frequency.
Thanks a bunch.
Anh Tran
On Thu, Jun 19, 2008 at 3:33 PM, milton ruser <[EMAIL PROTECTED]>
wrote:
> Hi Anh,
>
> How about the reply by Dimitris?
>
> Kind rega
Hello,
My package has passed all the R CMD CHECK steps except one. There is an
object which I placed in a sysdata.rda file (located in the 'R' directory of
the source package). Even though users have no need to access this object,
which is a character vector of parameters fed to Fortran code, R CMD
Alfredo
> -Original Message-
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] On Behalf Of Alfredo
> Alessandrini
> Sent: Friday, 20 June 2008 10:56 a.m.
> To: r-help@r-project.org
> Subject: [R] colnames of a column
>
> Hi,
>
> With this data.frame:
>
> > class(rwl)
> [1] "data
Try
names(rwl[1])
2008/6/19, Alfredo Alessandrini <[EMAIL PROTECTED]>:
> Hi,
>
> With this data.frame:
>
>> class(rwl)
> [1] "data.frame"
>
>>rwl
> 0028002F 0028013F 0028032F
> 1833 3.39 NA NA
> 1834 3.09 NA NA
> 1835 3.05 NA NA
> 1836 3.31
Hi Tyler,
I don´t know if I understood well.
Try this. Case not work I try again and again :-)
df<-read.csv("http://www.nabble.com/file/p18018170/subdata.csv";)
df.min.diff<-aggregate(df["diff"], df[c("day")], min)
df.subset<-subset(df, paste(df$day, df$diff) %in% paste(df.min.diff$day,
df.min.
Hi,
With this data.frame:
> class(rwl)
[1] "data.frame"
>rwl
0028002F 0028013F 0028032F
1833 3.39 NA NA
1834 3.09 NA NA
1835 3.05 NA NA
1836 3.31 NA NA
1837 2.26 NA NA
> colnames(rwl)
[1] "0028002F" "0028013F" "00
Hi Anh,
How about the reply by Dimitris?
Kind regards,
miltinho
Brazil
-- Forwarded message --
From: Dimitris Rizopoulos <[EMAIL PROTECTED]>
Date: Jun 16, 2008 4:05 AM
Subject: Re: [R] Superimposing Line over Histogram in Density Plot
To: Gundala Viswanath <[EMAIL PROTECTED]>
Cc
I'm testing R version 2.7.0 on windows and there seems to be a
compatibility issue with objects that were created by "approxfun" in
older versions. As long as the objects were created in version 2.7.0
things work ok, but calling the interpolated functions from R version
2.0.1 causes this error:
Er
On 19.06.2008, at 20:17, ppatel3026 wrote:
I would like to replace "\r\n" with "" in a character string, where
"\r\n"
exists only between < and >, how could I do that?
Initial:
characterString = "\r\n"
Result:
characterString = "\r\nXML>"
Tried with sub(below) but it only replaces the f
Hi All,
I'm wondering how I can print one large/long character on several lines so that
the output will not overflow a page. Setting fill be TRUE or even numbers does
not help. An example is below:
ipuFile <- file("input.txt", "w")
cat("This is a very long character and I want to pr
See ?density
On Thu, Jun 19, 2008 at 6:16 PM, Anh Tran <[EMAIL PROTECTED]> wrote:
> Hi all,
> What parameter should I feed to the hist function to draw a line, not bar
> graph for a histogram? Smoothed line would be great too.
> I've looked at curve() for normal distribution but it's not what I n
Hi all,
What parameter should I feed to the hist function to draw a line, not bar
graph for a histogram? Smoothed line would be great too.
I've looked at curve() for normal distribution but it's not what I need. I
need some curve on top of the histogram (fit to the actual data). Just as a
way to il
Hi AA
Ask on the bioconductor mailing list, following the 'mailing lists' link
on the front page http://bioconductor.org
and...
A A wrote:
Hi, I am trying to install Bioconductor onto R version 2.7.0 for Windows. I
installed R, then followed the instructions on
http://www.bioconductor.org
http://www.nabble.com/file/p18018170/subdata.csv subdata.csv
I've attached 100 rows of a data frame I am working with.
I have one factor, id, with 27 levels. There are two columns of reference
data, x and y (UTM coordinates), one column "date" in POSIXct format, and
one column "diff" in times
Thompson, David (MNR) wrote:
-Original Message-
From: Peter Dalgaard [mailto:[EMAIL PROTECTED]
Sent: June 19, 2008 04:23 PM
To: Thompson, David (MNR)
Cc: r-help@r-project.org
Subject: Re: [R] YAPMQ - Yet Another PlotMath Question
Thompson, David (MNR) wrote:
Hello,
I'm having tr
Dear colleagues,
Can anyone of you tell me how to write a "nabla" symbol in an R graph?
Thanks in advance,
Nuno
__
Centro de Oceanografia - IO-FCUL, Portugal
Center for Quantitative Fisheries Ecology - ODU, USA
[[altern
>-Original Message-
>From: Katharine Mullen [mailto:[EMAIL PROTECTED]
>Sent: June 19, 2008 04:26 PM
>To: Thompson, David (MNR)
>Cc: r-help@r-project.org
>Subject: Re: [R] YAPMQ - Yet Another PlotMath Question
>
>by example:
>
>slope <- 45
>plot(1:10)
>text(2, 7, labels = expression(45~degr
> Note that the R-project page (www.r-project.org)
> and CRAN are two "things", albeit closely related.
> CRAN is for "DOWNLOAD"ing, including free contributed docs.
> So that is the main reason, "contrib.docs" are not there in the
> www.r-project.org sidebar.
Why does there need to be two site
Hi Mona, I cannot get it done with the princomp and the biplot commands
either (maybe somebody can), but there are always many ways to Rome. This is
how you can do it (below). However, the label=rep... below assumes that your
values are in order, i.e. that you really want to plot the first fifty ro
Hi, I am trying to install Bioconductor onto R version 2.7.0 for Windows. I
installed R, then followed the instructions on
http://www.bioconductor.org/download, which state that you should type the
following:
source("http://bioconductor.org/biocLite.R";)
biocLite()
When I do that, I get the f
>-Original Message-
>From: Peter Dalgaard [mailto:[EMAIL PROTECTED]
>Sent: June 19, 2008 04:23 PM
>To: Thompson, David (MNR)
>Cc: r-help@r-project.org
>Subject: Re: [R] YAPMQ - Yet Another PlotMath Question
>
>Thompson, David (MNR) wrote:
>> Hello,
>>
>> I'm having trouble finding (remembe
by example:
slope <- 45
plot(1:10)
text(2, 7, labels = expression(45~degree)) ;
text(2, 5, labels = substitute(paste(slope * degree), list(slope=45)))
text(2, 3, labels = substitute(paste(lambda * " = " * mt * " (nm)"),
list(mt = 33)))
On Thu, 19 Jun 2008, Thompson, David (MNR) wrote:
> H
Dani
> I have a dataframe named myMatrix with the structure
If it really is a dataframe, why is it called myMatrix :-) I guess you
actually have a factor matrix. From the message below, Cr would appear to be a
factor.
There are some fundamental distinctions in R (such as between a matrix and
Thompson, David (MNR) wrote:
Hello,
I'm having trouble finding (remembering) how to pass values into text
functions in plots, as demonstrated by:
slope <- 45 ; plot(1:10) ; text(2, 7, labels = expression(45~degree)) ;
text(2, 5, labels = paste(bquote(.(slope)), expression(degree)))
text(2,
On 6/19/2008 12:51 PM, Jehol wrote:
Dear all,
there is much in these forums about adding a line to a
contour/filled.contour plot, but I haven't found hints for the following. I
apologize in advance if I just missed the right one.
I'm having a standard filled.contour plot to which I want to add a
Hello,
I'm having trouble finding (remembering) how to pass values into text
functions in plots, as demonstrated by:
slope <- 45 ; plot(1:10) ; text(2, 7, labels = expression(45~degree)) ;
text(2, 5, labels = paste(bquote(.(slope)), expression(degree)))
Thanx, DaveT.
Taka,
My appogizes. I didn't realize that cluster depends on the latest
beta version of R. I have uploaded the latest version of R-base to
the sevrers, but it will take a few hours for things to sync to all
CRAN servers.
In the meantime, you can download a version of r-cran-cluster here:
http:
source('yourscript.R')
on 06/19/2008 03:11 PM [EMAIL PROTECTED] said the following:
Dear R-Users,
I've written a number of functions in a .R/script file. I would like to
call those functions from another script file. How can I execute all the
code in a script file so that the functions are av
Dear R-users,
This is partially a R question and partially general econometrics.
I have three time series which are somewhat "dissimilar": plotting their
histograms indicates that they do not come from the same distribution,
never mind a normal distribution.
I wish to predict the first as a fu
Thank you all for your interest in this. The ARPACK library looks
like a very interesting option, I wish I had some experience in
interfacing R with such libraries. I'll try to learn on a simple
example first, and if successful I will try to adapt the igraphlib
interface to provide the desi
Thanks all for your help!
Peter Dalgaard wrote:
>
> Prof Brian Ripley wrote:
>> For the record, frame=1 and where=1 are not the same thing (whereas
>> frame=0 and where=0 are both the session database): assign() in S has
>> both 'frame' and 'where' arguments.
>>
> Drats... I stand corrected.
Hi Tolga,
See ?source
HTH,
Jorge
On Thu, Jun 19, 2008 at 3:11 PM, <[EMAIL PROTECTED]> wrote:
> Dear R-Users,
>
> I've written a number of functions in a .R/script file. I would like to
> call those functions from another script file. How can I execute all the
> code in a script file so that t
Many thanks all,
Tolga
"Jorge Ivan Velez" <[EMAIL PROTECTED]>
19/06/2008 20:19
To
[EMAIL PROTECTED]
cc
r-help@r-project.org
Subject
Re: [R] How can I execute a .R/script file
Hi Tolga,
See ?source
HTH,
Jorge
On Thu, Jun 19, 2008 at 3:11 PM, <[EMAIL PROTECTED]> wrote:
Dear R-Users,
Dear Tolga,
Check the help for "source" (?source).
HTH,
R.
On Thu, Jun 19, 2008 at 9:11 PM, <[EMAIL PROTECTED]> wrote:
> Dear R-Users,
>
> I've written a number of functions in a .R/script file. I would like to
> call those functions from another script file. How can I execute all the
> code
Ah.. It is source() ...apologies for the waste of time,
Tolga
Tolga I Uzuner/JPMCHASE
19/06/2008 20:11
To
r-help@r-project.org
cc
Subject
How can I execute a .R/script file
Dear R-Users,
I've written a number of functions in a .R/script file. I would like to
call those functions from
Dear R-Users,
I've written a number of functions in a .R/script file. I would like to
call those functions from another script file. How can I execute all the
code in a script file so that the functions are available for use in my
other script file ?
I have tried help.search("script") and vari
This depends on the id column. If all the id's are the same and in the exact
same order then look at ?cbind.
If you have different numbers or different ids in the two id columns see ?merge
--- On Tue, 6/17/08, calundergrad <[EMAIL PROTECTED]> wrote:
> From: calundergrad <[EMAIL PROTECTED]>
>
On Thu, Jun 19, 2008 at 2:17 PM, ppatel3026
<[EMAIL PROTECTED]> wrote:
>
> I would like to replace "\r\n" with "" in a character string, where "\r\n"
> exists only between < and >, how could I do that?
>
> Initial:
> characterString = " id=\"F\r\n2\">\r\n"
>
> Result:
> characterString = "\r\n"
>
>
Dear all,
there is much in these forums about adding a line to a
contour/filled.contour plot, but I haven't found hints for the following. I
apologize in advance if I just missed the right one.
I'm having a standard filled.contour plot to which I want to add a line
passing through some specific z
--- On Thu, 6/19/08, Martin Maechler <[EMAIL PROTECTED]> wrote:
> From: Martin Maechler <[EMAIL PROTECTED]>
> Subject: Re: [R] R web site-Useability & finding varous bits of documentation
> To: [EMAIL PROTECTED]
> Cc: "R R-help" <[EMAIL PROTECTED]>
> Received: Thursday, June 19, 2008, 12:17 PM
>
Le jeu. 19 juin à 10:55, [EMAIL PROTECTED] a écrit :
Hi,
I have been trying to install R for Ubuntu linux. Strangely, I got
the dependency error message below.
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This
Hi,
I am reinstalling R for Ubuntu Hardy using a CRAN mirror. I
successfully installed R 2.6.2, but when I type 'R' in a terminal it
says,
[EMAIL PROTECTED]:~$ R
.: 204: Can't open /usr/local/lib64/R/etc/ldpaths
And it seems like my R is at /usr/lib64/' not /usr/local/lib64. So I am
thinkin
On 6/19/2008 1:54 PM, stephen sefick wrote:
#is there a way to get NA in the table of descriptive statistics instead of
the function stopping Thank you in advance
Replace sd() with something like this:
mysd <- function(x, na.rm=TRUE){ifelse(all(is.na(x)), NA, sd(x,
na.rm=TRUE))}
Or con
Quick comment. Use an environment to hold your "fields" and then pass
around the environment variable. Any modification to variables inside
the environment done from anywhere (inside/outside functions) will be
persistent. Then wrap this up in a class structure, overload, say,
'$', '[[', '$<-', '
I would like to replace "\r\n" with "" in a character string, where "\r\n"
exists only between < and >, how could I do that?
Initial:
characterString = "\r\n"
Result:
characterString = "\r\n"
Tried with sub(below) but it only replaces the first instance and I am not
sure how to pattern match s
Gabor:
Thank you so much for your prompt reply.
Tudor
Quoting Gabor Grothendieck <[EMAIL PROTECTED]>:
> There is some sample code here:
>
> http://wiki.r-project.org/rwiki/doku.php?id=tips:graphics-misc:translucency
>
> On Mon, Jun 16, 2008 at 11:09 PM, Tudor Bodea <[EMAIL PROTECTED]>
> wrote:
Again thanks Chuck but I doubt any newbie who has heard about R and wants to
read some of the rather good documentation available is going to use that.
What I am trying to point out is that the R site is not the most easilly
navigated for a newbie.
Think of it like visiting your local bank's
#is there a way to get NA in the table of descriptive statistics instead of
the function stopping Thank you in advance
#data
x.f <- structure(list(Site = structure(c(9L, 9L, 9L, 9L, 9L, 9L, 9L,
9L, 9L, 9L, 9L, 9L, 9L, 9L, 9L, 9L, 9L, 9L, 9L, 9L, 9L, 9L, 9L,
9L, 9L, 9L, 9L), .Label = c("BC", "HC",
Thanks Chuck but that does not actually answer my question. Those navbars do
not take me directly to the "Contributed Documentation" nor "Publications
related to R"
They take me to Books or "R Documentation".
I still do not see any what for a newbie to find their way from the main R page
to
Dear all,
I'm writing to check with you whether there is a way to create .exe file(or
something like that) with R. Now working on creating a program to take inputs
from users (with tcl/tk), I would appreciate any idea to make the program run
on its own rather than every time having to run my so
> "KateM" == Katharine Mullen <[EMAIL PROTECTED]>
> on Thu, 19 Jun 2008 11:50:22 +0200 (CEST) writes:
KateM> On Thu, 19 Jun 2008, Simon Wood wrote:
>> >
>> > I happily use eigen() to compute the eigenvalues and
>> eigenvectors of > a fairly large matrix (200x200, say),
Hi again Jeff...
Jeffrey Spies <[EMAIL PROTECTED]> writes:
> Thanks for the response, Martin. While the solutions offered update the
> object appropriately, we wouldn't get the desired return value (a string
> followed by the counter, "unique_1") when the methods are called. Do you
> know a way
On Thu, 19 Jun 2008, Charles C. Berry wrote:
On Thu, 19 Jun 2008, John Kane wrote:
I was starting to write a note to a prospective R-user and came to the
point of explaining how to get useful introductory information on R.
After mentioning the Into and the FAQs I went on to try to explain
on 06/19/2008 09:59 AM Gundala Viswanath wrote:
Hi,
I have the following dataset (simplified for example).
__DATA__
300.35 200.25 104.30
22.00 31.12 89.99
444.50 22.10 43.00
22.10 200.55 66.77
Now from that I wish to do the following:
1. Compute variance of each row
2. Pick top-2 row with hi
On Thu, 2008-06-19 at 10:42 -0400, Bryan Hanson wrote:
> [I've ommitted some of the conversation so far...]
>
> > E.g. in a logistic model, with (say) eta = beta_0 + beta_1*x one may
> > find, on the
> > linear predictor scale, A and B (say) such that P(A <= eta <= B) = 0.95.
> >
> > Then P(expit
On Thu, 19 Jun 2008, John Kane wrote:
I was starting to write a note to a prospective R-user and came to the point of
explaining how to get useful introductory information on R.
After mentioning the Into and the FAQs I went on to try to explain how to use a
lot of the contributed information.
Hi,
I am using the mle2 method of the package 'bbmle'. The method is calling as
far as I understood it the optim method "L-BFGS-B" (this is the method I
use). The latter one allows the user to impose box constraints on the
variables, i.e. to give lower and upper bounds. It is important that the
i
> "JK" == John Kane <[EMAIL PROTECTED]>
> on Thu, 19 Jun 2008 06:50:18 -0700 (PDT) writes:
JK> I was starting to write a note to a prospective R-user
JK> and came to the point of explaining how to get useful
JK> introductory information on R. After mentioning the
JK> I
Thanks for the response, Martin. While the solutions offered update the
object appropriately, we wouldn't get the desired return value (a string
followed by the counter, "unique_1") when the methods are called. Do you
know a way of dealing with this?
Jeff.
Martin Morgan wrote:
>
> Hi Jeff --
On Tue, 17 Jun 2008, lhaba wrote:
Hi,
i need to minimize a quadratic function with boundary condidtions and one
equality condition.
In order to do that i converted the equality constraint into 2 inequality
constaints
You can't do that with constrOptim. constrOptim requires the interior of the
On 6/19/2008 11:01 AM, Patrick Ayscue wrote:
Hello,
Is there a way to extract output objects from a stats test without viewing
the entire output? I am trying to do so in the following:
define a vector of length j
for( i in 1: length (vector)) {
vector[i] = cor.test (datavector1, datavector2[i
Dear Patrick,
Assuming that datavector1 is the first column of your data set, you can try:
# Data set
set.seed(123)
y=matrix(rnorm(100*6),ncol=6)
rownames(y)=1:100
colnames(y)=c('datavector1',paste('X',1:5,sep=""))
y[1:10,]
# Correlations
RES=apply(y[,-1],2,function(y,x)
cor.test(x,y,method="spe
Hi Jeff --
two different scenarios are to overwrite the current object, along the
lines of
y <- uniquify(y)
where uniquify is a method like createUniqueName but returns the
(modified) instance rather than unique name
setMethod('uniquify', 'MyMatrix', function(x) {
[EMAIL PROTECTED] <- # som
See ?rect
library(zoo)
d1 <- as.Date("2007-04-12")
d2 <- as.Date("2008-05-14")
plot(SP500, type = "n")
rect(d1, par("usr")[3], d2, par("usr")[4], col = "red", border = 0)
lines(SP500)
Also, there is an example using the lattice/grid-based xyplot.zoo in ?xyplot.zoo
On Thu, Jun 19, 2008 at 10:48 A
First of all, you need to store as a list not a vector if you;re storing the
entire output. Otherwise, you can just store, for example, cor.test(...)$p.value
On Thu, 19 Jun 2008 11:01:42 -0400
"Patrick Ayscue" <[EMAIL PROTECTED]> wrote:
> Hello,
>
> Is there a way to extract output objects fr
The short answer on comparing R and Matlab is that it depends on
your benchmark and which church you happen to frequent. Some people
swear that Matlab is superior, but I haven't seen the evidence for
that. The benchmarks that come closer to being transparent are more
equivocal, as far as
Hello,
Is there a way to extract output objects from a stats test without viewing
the entire output? I am trying to do so in the following:
define a vector of length j
for( i in 1: length (vector)) {
vector[i] = cor.test (datavector1, datavector2[i], method=("spearman"))
}
I would like the rep
Dear Gundala,
Try this:
# Data set
DF=read.table(textConnection("300.35 200.25 104.30
22.00 31.12 89.99
444.50 22.10 43.00
22.10 200.55 66.77"),header=FALSE,sep="")
# Variances
VAR=apply(DF,1,var)
# Order
pos=order(VAR)
# Print VAR and pos
VAR
pos
# ordered VAR
VAR[pos]
# top-2 highest VAR
On Thu, Jun 19, 2008 at 10:55:01AM -0400, [EMAIL PROTECTED] wrote:
> Hi,
>
> I have been trying to install R for Ubuntu linux. Strangely, I got the
> dependency error message below.
>
> Reading package lists... Done
> Building dependency tree
> Reading state information... Done
> Some packages c
Hi,
I have the following dataset (simplified for example).
__DATA__
300.35 200.25 104.30
22.00 31.12 89.99
444.50 22.10 43.00
22.10 200.55 66.77
Now from that I wish to do the following:
1. Compute variance of each row
2. Pick top-2 row with highest variance
3. Store those selected rows for fu
Hi,
I have been trying to install R for Ubuntu linux. Strangely, I got the
dependency error message below.
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situatio
Dear list members,
How can I shade the background area of a zoo time series object between
specific dates?
eg.
library(tseries)
library(zoo)
SP500<-get.hist.quote("^GSPC", start = "1990-01-01", quote =
"Close")
plot(SP500)
How can I produce the same plot but with a (say) red
Hi all
I have 2 loops with 2 counters, say outer loop counter is X and inner loop
counter is Y. In outer loop a data file with known number of columns and
unknown number of rows is generated in each script iteration. What inner loop
should do is to read this file line by line and genera
[I've ommitted some of the conversation so far...]
> E.g. in a logistic model, with (say) eta = beta_0 + beta_1*x one may
> find, on the
> linear predictor scale, A and B (say) such that P(A <= eta <= B) = 0.95.
>
> Then P(expit(A) <= expit(eta) <= expit(B)) = 0.95, which is exactly
> what is wan
“Notes on the use of R for psychology experiments and questionnaires” by
Jonathan Baron and Yuelin Li on the R website.
--- On Wed, 6/18/08, Marvin Lists <[EMAIL PROTECTED]> wrote:
> From: Marvin Lists <[EMAIL PROTECTED]>
> Subject: [R] help with manipulating data frames (survey analysis)
> T
Baptiste,
the igraph ARPACK interface is quite experimental, and igraph includes
only the ARPACK files (converted to C) that it needs to calculate
some graph measures on sparse graphs. Btw. the development version
of igraph is a bit better in this respect, I can send you a link to
the developme
Dear all,
Thank you for the suggestions and pointers. It looks like I'll need
to do some interface with Fortran/C code. The igraph package seems to
provide an interface with ARPACK, albeit not with the options I need,
so it could be a good starting point.
Best regards,
baptiste
On 19 J
regexpr("ba", strings)
On Thu, Jun 19, 2008 at 1:18 AM, Daren Tan <[EMAIL PROTECTED]> wrote:
>
>
> For example,
>
> strings <- c("", "","ccba").
>
> How to get "", "" that do not contain "ba" ?
Here are three ways:
> strings[regexpr("ba", strings) < 0]
[1] "" ""
> setdif
I was starting to write a note to a prospective R-user and came to the point of
explaining how to get useful introductory information on R.
After mentioning the Into and the FAQs I went on to try to explain how to use a
lot of the contributed information.
However I realised that there seems t
On Wed, Jun 18, 2008 at 9:09 PM, Tariq Perwez <[EMAIL PROTECTED]> wrote:
> Hi
> I just realized that when I use linear regression to draw a line through my
> data points with something like the following:
>
> abline(lm(y ~ x))
>
>
> the length of the line is infinite, i.e., the line goes beyond the
Hi Paul,
Thanks for the answer. I temporarily did it with the subplot function
from the TeachingDemos package but I like this version much better.
Best,
Victor.
Paul Hiemstra wrote:
Victor Homar wrote:
Dear R users and helpers,
I'm trying to find an example of a histogram plot as an inset
Hi,
I am using the mle2 method of the package 'bbmle'. The method is calling as
far as I understood it the optim method "L-BFGS-B" (this is the method I
use). The latter one allows the user to impose box constraints on the
variables, i.e. to give lower and upper bounds. It is important that the
in
This discussion has already occurred- to my knowledge at least once. I
would suggest searching the archived list, and see what you get. If you
still have questions after you have a look then fire a couple of specifics,
but speaking for myself I don't know anything about matlab only S (and even
t
1 - 100 of 126 matches
Mail list logo