similar to: lm/model.frame.default surgery: Am I doing something crazy?

Displaying 20 results from an estimated 2000 matches similar to: "lm/model.frame.default surgery: Am I doing something crazy?"

2000 Sep 28
1
non-ideal behavior in princomp
This problem is not limited to R, but R is one of the packages in which it arises. princomp is a nice function which creates an object for which inspection methods have been written. Unfortunately, princomp does not admit cases in which the x matrix is wider than high (i. e. more variables than observations). Such cases are typical in spectroscopy and related disciplines. It would be nice if the
2002 Feb 14
0
two comments regarding predict.lm
Here is the first one. It concerns the handling of multiple offsets. The following lines creates a list with 3 explanatory variables and one response. > x<-seq(0,1,length=10);y<-sin(x);z<-cos(x); w<-x+y+z+rnorm(x) > data<-list(x=x,y=y,z=z,w=w) A lm is fitted with one explanatory variable and two offsets. So far, so good. >
2003 Aug 13
1
The desire for prettier and cheaper images ...
This might be easy (but I didn't find an answer in the archives). I'm trying to make nice looking images (using image()). To make them look nice (not jagged), it usually takes me at least 100x100 points. This can be slow for frequent redraws. Is there a smarter (less point intensive) way? I was thinking in terms of hexabins, for example, which for much less jagged looking regions,
2002 Dec 18
1
A little problem handling logicals in RMySQL under R1.6.1
There is a little problem in handling logicals in RMySQL: # here is the MySQL connection > con <MySQLConnection:(1816,0)> # here is the data frame > print(a<-data.frame(x=c(TRUE,FALSE),y=c(FALSE,TRUE))) x y 1 TRUE FALSE 2 FALSE TRUE # as promised, the two data frame columns are identified as logicals and # the field types are set to tinyint > field.types <-
2003 Aug 18
1
rterm not shutting down from ESS on Win32/could we help?
Hi to all who suffer from rterm not shutting down in xemacs/ESS on windows NT or 2000. Also hi to those who could eventually help. Here is some more information which could help and some ENCOURAGEMENT to contribute to a solution. 1. It may be an xemacs problem but it is more likely an interaction between rterm/comint/and xemacs. In fact, the problem started occurring around version R 1.6.0. I
2005 Feb 23
2
Slightly off topic but concerning R#DSC-2005
Has anyone seen an official announcement to DSC-2005. I saw and email exchange on the R-news list in mid January in which a date was announced unofficially. (to DSC-organizers: we need and "official" announcement to request funding and travel permission and flights from Europe to Seattle are starting to fill up, so this is urgent). Christian Ritter Functional Specialist Statistics Shell
2005 Jun 30
1
request/suggestion: modified names
For some time now I use a modified version of names (extract direction) of the following type: Names<- function (x,filter="^") { grep(filter,names(x),value=TRUE) } Request: Has anyone already written a version which goes the other way (that is, which allows assignment of the type Names(x,filter)<-...). Naive versions are obvious, but I think something would have to be done
2007 Jun 11
1
Looking for R-code for non-negative matrix factorization in the presence of Gaussian or Poisson noise
Hi all, Has any of you implemented code for non-negative matrix factorization to solve Y=T P' +E; dim(Y)=n,p ; dim(T)=n,nc; dim (P)=(p,nc); dim(E)=n,p where T and P must be non-negative and E either Gaussian or Poisson noise. I'm looking for two variants: 1. Easy (I think), T is known (that is we just want to solve the general inverse problem) 2. Harder (?), T is unknown (under some
2000 Sep 29
2
non-ideal behavior in princomp/ not a feature but a bug
... I checked and Brian and I are both right (see bottom for prior mail exchange). Let me explain: ============================================================= 1. Indeed, in principle, princomp allows data matrices with are wider than high. Example: > x1 [,1] [,2] [,3] [,4] [1,] 1 1 2 2 [2,] 1 1 2 2 > princomp(x1) Call: princomp(x = x1) Standard deviations:
2000 Sep 29
2
non-ideal behavior in princomp/ not a feature but a bug
... I checked and Brian and I are both right (see bottom for prior mail exchange). Let me explain: ============================================================= 1. Indeed, in principle, princomp allows data matrices with are wider than high. Example: > x1 [,1] [,2] [,3] [,4] [1,] 1 1 2 2 [2,] 1 1 2 2 > princomp(x1) Call: princomp(x = x1) Standard deviations:
2005 Jul 12
2
unexpected behavior in bwplot
R-2.1.1 on windows XP I just noticed something unpleasant when using bwplot (from lattice). In order to satisfy a wish from a client, I needed to produce sets of boxplots conditioned by another factor. My client didn't like the look of the boxplots (by default, they have a star to mark the median, instead of the commonly used line). I told him "no problem" dumped panel.bwplot,
2003 Sep 02
0
R/Chemometrics/reading .spa files into R.
Maybe someone out there has done this already .... (which would save me some time): For a repetitive chemometric task I need to retrieve spectra from a Nicolet IR acquisition system into R and analyze them there. The raw spectra are in files ending in the extension .spa. I can use the Omnic software to export them to .csv, but I would like to skip this step since it is manual. Has anyone of you
2006 Nov 30
1
Looking for nice implementations of rectangular scatterplot matrices
... finding myself doing this by hand one too many times ... maybe someone else has found a nice general solution ... I have a data frame containing n rows on p+q variables which I will call p.1, p2, ..., pp and q1, q2, ... qq. For simplicity all of these variables are continuous numeric. I want to create the following arrangement of plots: A scatterplot matrix which contains p times q panels
2006 Jul 11
0
Assistance with dll's to use with dyn.load
After having browsed the documentation for a while without discovering what I am looking for, maybe one of you would know ... What I want to do: I have two fortran files MC.f and ESCA.f. In MC.f there is a call to a routine called lpost. This routine (lpost) is defined (among other things) in ESCA.f. Under linux, I can do the following: R CMD SHLIB MC.f and R CMD SHLIB ESCA.f followed by
2002 Dec 19
0
Ongoing unhappiness with NA and factor behavior of distributed lm/predict.lm
Hi all, I''m still not quite happy with the NA and factor handling of lm and predict.lm in R1.6.1 (forcing me to use my not very skillfully crafted patches). Here is the problem 1: >
2000 Aug 07
0
filtering spectra
Hi all, I'll have to filter Raman spectra and I would like to do so in R. I'm trying to figure out how. Maybe one of you could help me ... This is what I have to do: General: separate the real spectrum (the set of peaks) from two contaminations: a drifting background and (white) noise Constraints (which should help the task): A - the spectrum is positive B - the spectrum is long
2000 Sep 06
3
funny arrows
The result of > plot(c(-1,1),c(-1,1),type="n") > arrows(0,0,1,1) > arrows(0,0,0,0) is not what I expected. The first arrow is drawn correctly. The second does not collapse to a point but goes from (0,0) off to (-infinity,infinity). I guess something is divided by zero in the internal function. Chris. =============================================== platform Windows arch
2004 Sep 09
2
Handling the windows clipboard/32KB limit
(R 1.9.1; Windows 2000;) I'm just comparing ease of use, speed, etc for methods of transferring data frames in the Excel, MySQL, R triangle. It turns out that going from Excel to R (when doing this carefully). Using the clipboard is actually quite fast and efficient (2 seconds for transferring 120 000 cells on a common desktop computer as compared to much longer for going the RODBC route,
2014 Jan 03
1
Tab formatting in dummy.coef.R
Happy New Year I recognize this is a low priority issue, but... I'll fix it if you let me. There are some TABs where R style calls for 4 spaces. For example R-3.0.2/src/library/stats/R/dummy.coef.R. I never noticed this until today, when I was stranded on a deserted island with only the R source code and a Swiss Army knife (vi). Now I realize my ~.vimrc has tabstop set at 2, and it makes
2003 Mar 26
5
predict (PR#2686)
# r-bugs@r-project.org `predict' complains about new factor levels, even if the "new" levels are merely levels in the original that didn't occur in the original fit and were sensibly dropped, and that don't occur in the prediction data either. (At least if `drop.unused.levels' was set to TRUE, which the default.) test> scrunge.data.2_ data.frame( y=runif( 3),