similar to: specifying a model formula on the fly

Displaying 20 results from an estimated 4000 matches similar to: "specifying a model formula on the fly"

2001 Oct 06
0
calculating DNA mismatch distributions for large populations
Hi all, I am interested in calculating and displaying the distributions of pairwise comparisons between DNA sequences in populations. The comparisons are the number of nucleotide sites that differ between the two sequences (mismatches). My sequences are stored in a vector of strings. There is an additional vector of the same length that provides the indices to the DNA sequences. Finally, I
2000 Jul 11
2
warnings associated with logistic regression
Hi all, This is as much as statistical/estimation question as an R-specific one, but here goes. I am trying to use logistic regression to predict suitability of habitats for certain plant species. The response variable is a binary one that indicates whether a particular species is found at a site on the landscape. The independent variables represent physical characteristics of the landscape
2002 Mar 07
8
linear correlation?
Whether the two variables have the same units does not matter. Moreover, even if there were some way of converting cm to kg the correlation would still be the same because the correlation is invariant under unit conversion as it is invariant under multiplication of its arguments by a constant. As for your second question, the correlation estimator is a continuous function of each of the
2001 Sep 10
1
problems linking c++ code
I've been trying to learn about dynamically loading subroutines in R. Ultimately I would like to use this approach to implement some simulations. For the moment though, I've run into a problem compiling c++ code and loading it into R. The 'C/C++' and 'R'code below works fine when compiled and linked with gcc, but gives an error when the library is compiled and linked with
2006 Feb 07
1
matching tables
Dear Listers, I am trying to match tables that DO NOT have the same length. The tables result from the function "table()" so they look like this: table 1 2 3 4 3 5 7 table 2 1 2 3 6 4 5 I need the following output: (NOTICE THE ZEROS) 1 2 3 4 table1 0 3 5 7 table2 6 4 5 0 Unfortunately, I was not successful using "match()". Previous postings explain how to do
2006 Feb 23
1
R and marine protected areas: algorithms for site selection
Dear listers, a central problem in conservation biology is the selection of sites in reserve network design. many algorithms have been published, and I was wondering any have been implemented in R. I did not seen anything on CRAN or R-help, or on the web in general. Best regards, Eric Eric Pante ---------------------------------------------------------------- College of Charleston, Grice
2006 Jun 08
2
nested mixed-effect model: variance components
Dear listers, I am trying to assess variance components for a nested, mixed-effects model. I think I got an answer that make sense from R, but I have a warning message and I wanted to check that what I am looking at is actually what I need: my data are organized as transects within stations, stations within habitats, habitats within lagoons. lagoons: random, habitats: fixed the question is:
2002 Feb 19
1
krb5 switch functionality
Question, I have made numerous attempts at configuring the samba 2.3.3a program to include support for MIT Kerberos 5 v.1.2.3. The configure -help says that the switch to turn it on is"--with-krb5=base-dir". I have tried several different directories as the base-dir with no luck. During the coufigure, completes but the with-krb5 options is set to "no". The only time I
2001 Sep 04
2
fastest way to multiply each column of a matrix by a single vlaue
Let A be a m by n matrix and b a length n vector. What is the fastest vectorized code for doing for(j in 1:n) A[, j] <- A[, j]/b[j] ? solution 1: t(t(A)/b) solution 2: B <- matrix( rep(b, m), byrow=T, nrow=m ) A/B anything else? I have a program that uses this kind of operation million of times and I appreciate your input. Thanks. Jason Liao ===== Jason G. Liao Department of
2001 Sep 08
0
R-function available for noncentral hypergeometric distribution
For those who are interested, I have made available a R function for noncentral hypergeometric distribution at http://www.geocities.com/jg_liao/software/Hypergeometric/hypergeometric_in_R.txt The paper that describes the algorithm will appear in The American Statistician. The function does not run on S-plus as the R's scoping rule is used. Here is how the function can be used: > n1
2001 May 01
2
6 times faster by eliminating apply
This is some kind of follow-up to my previous posts. I have further improved the speed of my program 6 times by eliminating all the apply(). It turns out that apply is slow, is slower than direct loop, it is an order slower than a matrix operation alternative. Here is one example. The first apply version runs 19 seconds, the second loop version runs 13 seconds, the third matrix version runs 1
2008 May 15
0
partial_updates feature in rails 2.1, failing to save because of validate_presence _of on other attributes in the table
I am trying to use the new partial_updates feature in rails 2.1, http://dev.rubyonrails.org/changeset/9157 but it is failing by trying to use all validations in the model instead of just the changed attributes. The model works as I can successfully .save(false) but if I try a regular .save I get an error saying that it could not save because of validations problems. I want to use this to get
2006 Jan 19
1
matrix export
Dear listers, I need to export a distance matrix in the following format : a 0.0 1.0 0.2 1.0 1.0 b 1.0 0.0 1.0 1.0 1.0 c 0.2 1.0 0.0 1.0 1.0 d 1.0 1.0 1.0 0.0 1.0 e 1.0 1.0 1.0 1.0 0.0 I tried write.matrix() from the MASS library, which gives: a b c d e 0.0 1.0 0.2 1.0 1.0 1.0 0.0 1.0 1.0 1.0 0.2 1.0 0.0 1.0 1.0 1.0 1.0 1.0 0.0 1.0 1.0 1.0 1.0 1.0 0.0 Does anyone know of an R trick to change
2007 Aug 16
0
SYSLINUX Digest, Vol 53, Issue 12
> ----- Original Message ----- > From: syslinux-request at zytor.com > To: syslinux at zytor.com > Subject: SYSLINUX Digest, Vol 53, Issue 12 > Date: Wed, 15 Aug 2007 12:00:05 -0700 > Message: 4 > Date: Tue, 14 Aug 2007 17:02:44 -0700 > From: "H. Peter Anvin" <hpa at zytor.com> > Subject: Re: [syslinux] SYSLINUX-3.52-pre5: XP BOOTSEC.BIN Bug > To: For
2001 Apr 17
1
fastest R platform: follow-up and summary
The following runs in an eyeblink on my 700Mhz Thinkpad T-20 (256 MB RAM) with Windows NT: var(matrix(rnorm(4000000),ncol=4,nrow=1000000)) This also has the virtue of being quite readable. You could allow an arbitrary covariance matrix and mean vector and it increases the time slightly, but still only about 5 seconds. Regarding performance, having tons of RAM is crucial. My Windows NT and the
2005 Mar 03
3
creating a formula on-the-fly inside a function
I have a function that, among other things, runs a linear model and returns r2. But, the number of predictor variables passed to the function changes from 1 to 3. How can I change the formula inside the function depending on the number of variables passed in? An example: get.model.fit <- function(response.dat, pred1.dat, pred2.dat = NULL, pred3.dat = NULL) { res <- lm(response.dat ~
2007 Feb 07
4
tzdata - extra info.
Sorry for the extra info required, but I had digest mode turned on and wouldn't have received the mailing till tomorrow. I have since updated the data manually, but after 'yum update tzdata' was run, the zdump -v for EST5EDT and America/New_York all still showed a date of April 1, instead of March 11. After manually fixing, it is correct. This was mostly a question about why yum
2006 May 31
2
Login screen changes
I tested moving a box from Tao 1.0 to CentOS 3.7. All went well, as far as I can tell, with the OS upgrades, but I needed to rpm -ivh --force the desktop-* stuff. This was a minor thing to fix for no real purpose other than to just be doing it. I still get, though, the Tao screens when the graphic login screen appears. I have changed the Application->Settings->Login Screen->
2009 Jan 20
1
Can R be installed on a Windows Server for concurrent usage?
I apologize for this very naïve and stupid question. I have searched the archives and "googled" a number of different queries relating to this question and cannot find the answer. My Division is moving toward running an application server for all statistical applications because the Department of Veterans' Affairs has their computers locked down. They are locked down so much so
2006 Mar 30
1
Laptop freezes when trying to load R packages?
Hello I am having an R related problem and can't seem to fix it by looking at any of the online documentation. I have a laptop (using Windows XP home edition) and loaded R 2.2.1. I then designated a mirror (USA-NC). But when I try to load a package, it freezes. I have tried to close R, but it won't close; I end up having to restart the laptop. I have no problems with any other