Displaying 20 results from an estimated 1000 matches similar to: "Help with for"
2000 Sep 19
2
Simple command
Is there an "execute" command such that:
execute(paste("X[3]<-5"))
or
execute(paste("anything"))
where "anything" is executed by R??
Thanks,
Alex Ahgarin
________________________________________________________________
Data Management
ISC Inc.
Washington, DC.
-----------------------------------------------
FREE! The World's Best Email Address
2000 Dec 01
1
text in new window
Hello all,
For presentation and printing purposes I'd like to be able to open a new
window device and write text and/or include an object (mostly matrices or
lists).
I've tried around windows(), but which I'd expect to work doesn't:
windows(text(results)),
or windows(parse("Final result:",results))
-"results" is a numeric object-.
Thanks for any help,
Alex
1999 Dec 13
2
Combinations
I need some help here.
>From a vector of variable length (say, c(A,B,C,D), I need to obtain all
posible combinations (order doesn't matter) of the elements.
I would like a function such as:
function(x,c(A,B,C,D))
to give a matrix (for x=3) like:
A B C
A B D
A C D
B C D
or for x=2
A B
A C
A D
B C
B D
C D
And so on.
Any ideas??
Thank you,
Alex Ahgarin
Data Management
I.R.W. Co.
2002 Aug 01
2
A question from a newbee...
Hello .
I have a little question ..
I work with Anova (aov) and Manova (manova) and want to print some result in a
text file. I see the results with the summary function or the summary.aov
function but i do not know how to save the differents probabilities of error
in a value.
Sorry for my poor English
Thanks a lot.
--
Lamoral Julien
2000 Jan 06
1
No subject
I apologize in advance to those for who this wuestion may be too stupid.
Running R 0.091 on Windows 95 (a very old machine I'm afraid 486-66 16M)
When constructing a big matrix I get:
Error: heap memory (6144 Kb) exhausted [needed 7087 Kb more]
See "help(Memory)" on how to increase the heap size.
Help(Memory) tells me I must: (Quote)
Use command line options to set the memory
2002 May 14
2
quantile() and boxplot.stats()
Hello,
I faced something I can't understand. When I use boxplot.stats(1:10) and
quantiles(1:10) the results are different for 25% and 75%:
> boxplot.stats(1:10)
$stats
[1] 1.0 3.0 5.5 8.0 10.0
> quantile(1:10)
0% 25% 50% 75% 100%
1.00 3.25 5.50 7.75 10.00
Actually, I expected the value 3 for 25% and 8 for 75% as results of
quantile(1:10). Can you please explain me
1998 Apr 07
3
R-beta: spline problems(?)
Hi,
I am a total beginner with this whole thing so please have patience!
I am trying to run an S-plus program with a certain line:
spline(1:nrow(y), y[,1],n=100);
This crashes with:
Error: NAs in foreign function call (arg 8)
Apparently, this is caused by the last command of spline:
u <- seq(xmin, xmax, length.out = n)
.C("spline_eval", z$method, length(u), x = u, y =
2008 Jul 13
1
(no subject)
Hello everyone,
I am using the following code to try to calculate the mean :
dat<-read.table(file="C:\\Documents and Settings.....txt")
dat<-as.numeric(dat)
x1.m<mean(dat)
I am getting the following error message
Error in eval.with.vis(expr,envir,enclos):
(list) object cannot be coerced to type"double'
I do not understand what is wrong as I thought that I have changed
1998 Feb 12
1
R-beta: Quantile function
Is the following behaviour of the quantile function what one would expect?
> a <- 1:100
> quantile(a,.6)
60%
60.4
Philippe
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the
2008 Sep 18
1
about the whisker in boxplot
Hi, Dear R-users,
I have a problem when I drawing a boxplot. I want to extend the whisker to
the 5% and the 95% quantiles and only show the most extreme outlier, like
0.01% and 99.99% percentiles. What should I do?
I saw something on boxplot.stat, but even I define the parameter in
boxplot.stat, what I should do next? how to connect it to boxplot?
Thank you very much!
Catherine
--
View
2006 Aug 11
1
x tick labels - sparse?
Hi,
I'm stuck on creating a plot with x tick labels for every Nth tick
mark - how is that done? I don't see a simple solution to this in
help(plot) or help(par) and what I've tried is not working, eg, the
following does not work, although it seems intuitive to me that it
should work:
x <- seq(-100,1000,25)
y <- x * x
% find all the x values that are multiples of 100
tmp <-
2012 Apr 24
2
Basic matrix manipulation problem
Hello, this forum was very helpful yesterday with a simple question I had on
working with tables. What function will I need to use to do the following.
Move matrix a:
A B C D
x 1 2 3 4
y 5 6 7 8
to the mean of B&C and C&D:
BC CD
x 2.5 3.5
y 6.5 7.5
and then to the mean of B&CB, C&BC, C&CD, and D&CD:
AAB BAB
2008 Oct 03
1
NA's in segmented
I am trying to fit a very simple broken stick model using the package
"segmented" but I have hit a roadblock.
> str(data)
'data.frame': 18 obs. of 2 variables:
$ Bin : num 0.25 0.75 1.25 1.75 2.25 2.75 3.25 3.75 4.25 4.75 ...
$ LnFREQ: num 5.06 4.23 3.50 3.47 2.83 ...
I fit the lm easily:
> fit.lm<-lm(LnFREQ~Bin, data=id07)
But I keep getting an error
2011 Jul 09
3
Using str() in a function.
Using str() in a function.
I am in the early phase of learning R, and I find I spend a lot of time
trying to figure out what is actually in objects I have created or read in
from a file. I'm trying to make a simple little function to display a
couple of things about a object, let's say the summary() and the str(),
sequentially, preferably without a bunch of surplus lines between them. I
2011 Mar 24
1
Various typo in spec
Hi,
I have few questions on the specification.
* Just to understand :
- What is the interest of super blocks ? Is it to save place when
recording coded block flags (7.3) ?
- What is the advantage of using the coded order ? it is more often
easier with raster order (especially to find neighbor in 7.8.1 for
exemple). Is it to simplify the correspondence between block, macro
block
2004 Feb 13
3
Calculate Closest 5 Cases?
I've only begun investigating R as a substitute for SPSS.
I have a need to identify for each CASE the closest (or most similar) 5
other CASES (not including itself as it is automatically the closest). I
have a fairly large matrix (50000 cases by 50 vars). In SPSS, I can use Correlate > Distances to generate a matrix of similarity, but only on a small sample. The entire matrix can not
2009 Aug 13
1
R code to reproduce (while studying) Bates & Watts 1988
Hi R users,
I'm here trying to understand correlated residuals in nonlinear estimation.
I'm reading/studying the book Bates, D. M. and D. G. Watts, (1988),
/Nonlinear regression analysis and its applications/, Wiley, NY. pages
92-94, trying to reproduce the figures and to find out the code in R to
perform the necessary calculations.
I also consulted Pinheiro and Bates, but without
2010 May 11
2
Regex and gsub
Dear group,
Here is my df :
df3 <-
structure(list(DESCRIPTION = c("COPPER May/10", "COTTON NO.2 Jul/10",
"CRUDE OIL miNY May/10", "GOLD Jun/10", "ROBUSTA COFFEE (10) Jul/10",
"SOYBEANS Jul/10", "SUGAR NO.11 Jul/10", "SUGAR NO.11 May/10",
"WHEAT Jul/10", "SPCL HIGH GRADE ZINC USD",
2013 Jan 04
3
building a regression model
Hi
I am trying to build a regression model. My data looks like this:
A B C D E
1 1 1 2.57 5
2 0 0 1.64 3
0 5 1 4.8 1
1 3 0 3.56 168
1 1 1 2.13 1
0 3 1 5 168
2 0 0 7.75 28
4 0 2 2.85 168
3 0 1 1.89 6
1 1 1 2.33 3
3 2 2 1.77 168
1 0 0 1.38 0.04
0 6 1 4.57 168
2 2 2 2.86 1
3 1 1 4.11 168
3 0 2 3 84
1 1 1 2.5 56
where E is a response variable and A, B, C,
2008 Jun 18
4
inverse cumsum
I've a matrix like this:
1985 1.38 1.27 1.84 2.10 0.59 3.47
1986 1.05 1.13 1.21 1.54 0.21 2.14
1987 1.33 1.21 1.77 1.44 0.27 2.85
1988 1.86 1.06 2.33 2.14 0.55 1.40
1989 2.10 0.65 2.74 2.43 1.19 1.45
1990 1.55 0.00 1.59 1.94 0.99 2.14
1991 0.92