similar to: query in R

Displaying 20 results from an estimated 1000 matches similar to: "query in R"

2006 Nov 30
4
R_WinEdt question
if I want to put fig1plot to the left, figYPplot to the right figYAaplot on the bottom. How to modify the following cod to do these? \begin{figure}[H] \centering \begin{minipage}[t]{0.5\textwidth} \centering <<label=fig1plot,fig=TRUE,echo=FALSE>>= <<fig1plot>> @ %\caption{Caption 1} \end{minipage} \begin{minipage}[t]{0.5\textwidth} \centering
2006 Nov 08
2
Sweave and font problems
Dear All, Having now successfully started using Sweave, I have just noticed an odd side effect with fonts. Using plain LaTeX, I have had no problems using \usepackage{palatino} or \usepackage{times} and the font correctly changes. However, once I convert the tex document into Snw, and run it through R CMD SWEAVE, LaTeX seems to ignore this package directive. The LaTeX log suggests the font
2006 Oct 17
2
RODBC and NULL values
Dear All, Writing sooner than I thought I'd need to. I'm using R 2.4 on Mac OS X, with RODBC, PostgreSQL 8.1 and Actual's ODBC driver. I have all my data in Filemaker 8.5, but it is automatically exported into PostgreSQL for analysis as Filemaker's ODBC and JDBC access is awful, slow and has a tendency to crash. I have disability data where for each patient there is a survival
2007 Apr 16
2
Simplify simple code
Dear expeRts, I would simplify following code. --------------------------------------------- youtput <- function(x1, x2){ n <- length(x1) y <- vector(mode="numeric", length=n) for(i in 1:n){ if(x1[i] >=5 & x1[i] <= 10 & x2[i] >=5 & x2[i] <=10) y[i] <- 0.631 * x1[i]^0.55 * x2[i]^0.65 if(x1[i] >=10 & x1[i] <= 15 &
2005 Oct 21
2
curve fit
How to obtain the FUNCTION for the following smooth curve? x 0 100 250 500 1000 4000 y 1.8 1.2 1.02 0.99 0.97 0.85 Thanks, SJ --------------------------------- [[alternative HTML version deleted]]
2009 May 26
2
Problem accessing "row number" from subset on a dataframe
I would like to use the "row number" information returned from performing a subset command on a dataframe. For example, I would like to automatically delete some rows from a dataframe if they match a criteria. Here is my example below. data(airquality) names(airquality) subset(airquality, airquality$Month == 6) Now how do I delete the row numbers returned automatically? I
2006 Aug 15
4
nls
Is there anyway to change any y[i] value (i=2,...6) to make following NLS workable? x <- c(0,5,10,15,20,25,30) y <- c(1.00000,0.82000,0.68000,0.64000,0.66667,0.68667,0.64000) lm(1/y ~~ x) nls(1/y ~~ a+b*x^c, start=list(a=1.16122,b=0.01565,c=1), trace=TRUE) #0.0920573 : 1.16122 0.01565 1.00000 #Error in numericDeriv(form[[3]], names(ind), env) : # Missing value or
2007 Nov 06
3
Produce a multiple formats graphic
Is it possible to produce the same graphic in different formats in one shot? Now if I want to produce the same graphic in pdf, ps and jpeg I run the producing code, but I change the graphic device, and I choose successively : pdf(...) ps(...) jpeg(...) So in this case I run the same code 3 times, or I have to choose a format and use converters... Is it possible to produce the 3 graphics in once
2005 Nov 21
1
arima prediction
x<-c(-1.873....,-0.121) # 23 numerics; x.arma12 <- armaFit(x ~ arma(1,2)) #estimates y[t]= -0.11465 - 0.23767 y[t-1] - 0.14230 e[t-1] -0.85770 e[t-2] + e[t]; # ? how to predict 46 steps ahead based on 23 data points? # the following doesn't work since n is in armaSim rather than armaFit; predict(x.arima12, n.ahead=46) # Thanks ---------------------------------
2007 Jun 26
2
Aggregation of data frame with calculations of proportions
Dear all, I have been stuck on this problem, am rather struggling and would appreciate some advice if anyone can help. I apologise if this is a bit long-winded, but I've tried to limit it to the bare essentials, but don't know how to make it more generic! I have some slightly odd real world data that I'm looking at representing number of positive diagnoses for different diseases,
2005 Oct 21
1
change maxiter for nls
I typed the following commands but it still use maxiter=50 after the 2nd command: nls.control(maxiter = 1000) nls(......) Thanks! --------------------------------- [[alternative HTML version deleted]]
2006 Nov 08
1
nls
> y [1] 1 11 42 64 108 173 214 > t [1] 1 2 3 4 5 6 7 > nls(1/y ~ c*exp(-a*b*t)+1/b, start=list(a=0.001,b=250,c=5), trace=TRUE) 29.93322 : 0.001 250.000 5.000 Error in numericDeriv(form[[3]], names(ind), env) : Missing value or an infinity produced when evaluating the model # the start value for b is almost close to final estimates, # a is usually
2008 Apr 30
2
Lattice book
Dear all, I haven't seen this mentioned and presumably Dr. Deepayan Sarkar is too polite to advertise! I just received a flyer from Springer: A new book on Lattice released today!! http://www.springer.com/statistics/computational/book/978-0-387-75968-5?cm_mmc=NBA-_-Apr-08_UK_1753460-_-product-_-978-0-387-75968-5
2006 Oct 14
2
Sweave, R and complex latex projects
Hello all, I've been able to use R very successfully to run simple statistics and generate the plots I require. I've been evaluating Sweave, and have hit upon a small problem that I don't seem to be able to workaround. Sweave runs very well for single file latex documents, but I have a complex thesis made up of several parts and chapters. These are arranged with a master latex file
2007 Nov 13
1
R: Query an Access database based on a date attribute
It seems that Access needs that you surround the dates with a # symbol. You probably need something like. res <- sqlQuery(channel, "select * from test_table where market = 'atl-bos' and competitor = 'delta' and dd = #2007-11-20#") Hope this helps, Stefano -----Messaggio originale----- Da: r-help-bounces at r-project.org [mailto:r-help-bounces at r-project.org]Per
2008 May 02
1
Phil Spector's book
Since we're on the topic of book reviews, I just received Phil Spector's new R book called "Data Manipulation with R" and it is also quite a nice book. I haven't gone through it all and I won't give a detailed review but I have gotten a lot out of the first 100 pages that I have read. Note that I've been using R for almost 1.5 years so , for me, it's a
2006 Dec 09
2
Show number at risk on Kaplan Meier curve
Dear all, I'm using the "survival" package with R 2.4.0 on Mac OS X 10.4.8. I have two core statistics books (one of which is Altman's medical stats book) which suggest showing the number of individuals at risk at different time intervals on the Kaplan-Meier curve. My plot shows two curves that later cross, because of one significant outlier. I have two queries: Is there an
2007 Aug 05
1
t-test
Hi all, i'm trying to run a two-sample t-test. i have a longitudinal data that looks like this: idn age class 1 22 1 1 22 1 1 22 1 1 22 1 2 63 3 2 63 3 2 63 3 3 43 2 3 43 2 3 43 2 3 43 2 3 43 2 3 43 2 4 37 1 4 37
2007 Jul 23
2
R and Excel
? stato filtrato un testo allegato il cui set di caratteri non era indicato... Nome: non disponibile Url: https://stat.ethz.ch/pipermail/r-help/attachments/20070723/2d591177/attachment.pl
2007 Oct 21
1
Error in if loop
I have created a if loop as follows: name = "e" if (name == "v") { u = 0 } else u = 1 however i am getting error : Error: unexpected 'else' in "else" definitely I can write in : ifelse() form, however I want to write in this way. Can anyone tell me where is my error? thanks in advance --------------------------------- Forgot the famous last