2010/7/23 w 霍 hw_joyce...@hotmail.com:
I use the constrOptim to maximize a function with four constriants but the
answer does not leave from the starting value and there is only one outer
iteration. The function is defined as follows:
tm-function(p){
p1-p[1]; p2-p[2]; p3-p[3];
Dear All,
The following code should return 1, but it returns 0:
source(http://r-bc.googlecode.com/svn/trunk/R/bc.R;)
bc(9 % 2)
Do you confirm this bug?
Paul
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do
On Mon, Jul 26, 2010 at 11:42 PM, Gabor Grothendieck
ggrothendi...@gmail.com wrote:
The following code should return 1, but it returns 0:
source(http://r-bc.googlecode.com/svn/trunk/R/bc.R;)
bc(9 % 2)
See FAQ 2 on the r-bc package home page:
http://r-bc.googlecode.com
Thanks to all
On Tue, Jul 27, 2010 at 5:12 AM, Gabor Grothendieck
ggrothendi...@gmail.com wrote:
The following code should return 1, but it returns 0:
source(http://r-bc.googlecode.com/svn/trunk/R/bc.R;)
bc(9 % 2)
See FAQ 2 on the r-bc package home page:
http://r-bc.googlecode.com
Thanks to all
On Tue, Sep 28, 2010 at 9:47 PM, Leonardo Monasterio
leonardo.monaste...@gmail.com wrote:
In the function bellow I want to find the maximum value of v,
subject to the constrain that the sum of x is equal to 1.
I want to maximize:
v-t(x)%*%distance%*%x
Subject to:
sum(x)=1
Where:
x is a
Dear All,
Is there some way of drawing a boxplot, with R, when one does not have
the original continuous data, but only the data grouped in classes?
The function boxplot() can only deal with original data.
Thanks in advance,
Paul
__
On Thu, Oct 22, 2009 at 5:31 PM, Jakson A. Aquino
jaksonaqu...@gmail.com wrote:
Is there some way of drawing a boxplot, with R, when one does not have
the original continuous data, but only the data grouped in classes?
The function boxplot() can only deal with original data.
Do you mean a
On Mon, Dec 21, 2009 at 12:42 PM, Duncan Murdoch murd...@stats.uwo.ca wrote:
I've just posted a demo made with the rgl package to Youtube, visible here:
http://www.youtube.com/watch?v=prdZWQD7L5c
For future reference, here are the steps I used:
1. Design a shape to be displayed, and then
On 9/11/07, Paul Smith [EMAIL PROTECTED] wrote:
The package mratios can perform inferences for ratios of normal means.
Is there some other package to do the same but with non-normal
populations. Since I have got large samples, an asymptotic procedure
would be fine.
Thanks for all replies. I
On 9/17/07, snapperball [EMAIL PROTECTED] wrote:
I am using a number of large matrices in a project. I read a couple of the
matrices using the read.csv command. However in some instances, R does not
recognize the resulting matrices as consisting of numerical values (I
suspect R considers them
Dear All,
Can R plot graphs like the one at
http://www.mathwords.com/f/f_assets/floor_graph.gif
with the balls at the discontinuity points?
Thanks in advance,
Paul
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
Dear All,
Can R draw plots of functions on a Cartesian coordinate system with
axes like the ones shown at
http://en.wikipedia.org/wiki/Image:Cartesian-coordinate-system-with-circle.svg
?
I have already searched the R web-site, but found nothing.
Thanks in advance,
Paul
On 9/28/07, Frank E Harrell Jr [EMAIL PROTECTED] wrote:
I know how to export graphics as pdf files and then how to include
them in LaTeX documents. However, I do not know how to do in
order to
have the text of the graphics written with the font selected for the
LaTeX document. Is that
On 9/28/07, Duncan Murdoch [EMAIL PROTECTED] wrote:
Can R plot graphs like the one at
http://www.mathwords.com/f/f_assets/floor_graph.gif
with the balls at the discontinuity points?
You can use segments() to draw the segments and symbols() to draw the
balls. For example,
On 9/28/07, Duncan Murdoch [EMAIL PROTECTED] wrote:
Can R plot graphs like the one at
http://www.mathwords.com/f/f_assets/floor_graph.gif
with the balls at the discontinuity points?
You can use segments() to draw the segments and symbols() to draw the
balls. For example,
(1, pos=0)
axis(2, pos=0,at=c(-1,-0.5,0.5,1))
How can I have the y axis labels rotated clockwise?
Paul
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Charles Annis, P.E.
Sent: Friday, September 28, 2007 11:32 AM
To: 'Paul Smith'; 'r-help
On 9/28/07, Greg Snow [EMAIL PROTECTED] wrote:
Look at the las argument in ?par for the easiest solution (can be passed
to axis).
Thanks a lot, Greg! That is it!
Paul
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Paul Smith
Sent: Friday
Dear All,
Consider the following piece of code:
pdf(file=figure.pdf, family=Palatino)
plot(0,0,type='n', xlim=c(-20,20), ylim=c(0,2),xlab=,ylab=,axes=F)
text(-1.4,1.168,expression(italic(The font looks different when this
is seen with Acrobat Reader!)),xpd=T)
dev.off()
When viewing the produced
On 9/30/07, Prof Brian Ripley [EMAIL PROTECTED] wrote:
Consider the following piece of code:
pdf(file=figure.pdf, family=Palatino)
plot(0,0,type='n', xlim=c(-20,20), ylim=c(0,2),xlab=,ylab=,axes=F)
text(-1.4,1.168,expression(italic(The font looks different when this
is seen with
On 10/3/07, Paul Murrell [EMAIL PROTECTED] wrote:
With the following code:
pdf(file=figure.pdf,family=URWPalladio)
plot(0,0,type=n)
text(0,0,expression(integral(f(x)*dx, a, b)))
dev.off()
the integral symbol gets horrible. With other fonts, the same does not
occur. Is there some
Dear All,
Consider the following code:
pdf(file=figure.pdf,family=URWPalladio)
curve(dlnorm(x,0,1.5),0,10,xlim=c(0,10),ylim=c(0,0.85),axes=F,xlab=,ylab=f)
segments(exp(-1.5^2),0,exp(-1.5^2),dlnorm(exp(-1.5^2),0,1.5),lty=dashed)
segments(1,0,1,dlnorm(1,0,1.5),lty=dashed)
On 10/13/07, Rob Knell [EMAIL PROTECTED] wrote:
I'm trying to do a simulation that involves identifying the minimum
point between two peaks of a (usually) bimodal distribution. I can do
this easily if there are only two peaks:
CnBdens-density(Ys/Xs) #probability density function for ratio of
Dear All,
Is there any package to do multi-objective optimization? For instance,
consider the following problem:
maximize f(x,y) in order to x
and
maximize g(x,y) in order to y,
simultaneously, with x and y being the same both for f and g. Can R do
it numerically?
Thanks in advance,
Paul
On 10/17/07, Alberto Monteiro [EMAIL PROTECTED] wrote:
Is there any package to do multi-objective optimization? For instance,
consider the following problem:
maximize f(x,y) in order to x
and
maximize g(x,y) in order to y,
simultaneously, with x and y being the same both for f
On 10/17/07, Ravi Varadhan [EMAIL PROTECTED] wrote:
What if simultaneously maximizing f(x,y) and g(x,y) is an incompatible
objective?
Modifying Duncan's example slightly, What if:
f(x,y) = -(x-y)^2 and
g(x,y) = -(x-2)^2-(y-x-1)^2?
Here:
(1) = x = y
(2) = y = x + 1
(3) =
On 10/22/07, Denis Aydin [EMAIL PROTECTED] wrote:
I just wanted to save a graphic in the pdf-format. But id failed:
Fehler: Invalid font type
Zusätzlich: Warning messages:
1: font family not found in PostScript font database
2: font family not found in PostScript font database
I use R
Dear All,
Can R perform multivariate integration with infinite limits of integration?
Thanks in advance,
Paul
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide
On Nov 10, 2007 12:43 PM, Uwe Ligges [EMAIL PROTECTED] wrote:
Can R perform multivariate integration with infinite limits of integration?
No, R does numerical (not symbolical) calculations, hence it can never
perform integration (not even univariate) with infinite limits.
Not entirely true
On Nov 10, 2007 2:25 PM, affy snp [EMAIL PROTECTED] wrote:
I am wondering how to log-2 based transform a matrix with numeric values?
I tried CGHlog2-log2(CGH) but got an error. Then I found for log2(x) in R,
the x has to be a numeric or complex vector. Any method for a matrix?
One can use
On Nov 10, 2007 2:49 PM, affy snp [EMAIL PROTECTED] wrote:
My matrix looks like:
dim(CGH)
[1] 238304243
CGH[1:30,1:4]
WM806SignalA WM1716SignalA WM1862SignalA WM1963SignalA
SNP_A-1909444 1.59 1.48 1.78 2.59
SNP_A-2237149 2.24
Dear All,
Take this code:
f - function(x) exp(-x)*x-0.05
g - function(x) 0
curve(f,0,5)
curve(g,add=T)
Error in xy.coords(x, y) : 'x' and 'y' lengths differ
However, with
g - function(x) x-x
no error is generated.
Is this a bug? I am using
version
_
platform
On Feb 1, 2008 2:46 PM, Martin Maechler [EMAIL PROTECTED] wrote:
Take this code:
f - function(x) exp(-x)*x-0.05
g - function(x) 0
curve(f,0,5)
curve(g,add=T)
Error in xy.coords(x, y) : 'x' and 'y' lengths differ
However, with
On Tue, Feb 19, 2008 at 11:07 PM, Chris Rhoads
[EMAIL PROTECTED] wrote:
To start, let me confess to not being an experienced programmer, although I
have used R fairly
extensively in my work as a
graduate student in statistics.
I wish to find the root of a function of two variables that
Dear All,
Can R perform n-way ANOVA, i.e., with 3 or more factors?
Thanks in advance,
Paul
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
On Wed, Mar 5, 2008 at 7:41 PM, Prof Brian Ripley [EMAIL PROTECTED] wrote:
Can R perform n-way ANOVA, i.e., with 3 or more factors?
Yes. There are even examples on the help page!
Thanks, Prof. Ripley. I will have a look at it.
Paul
__
Dear All,
I am trying to install the rgl package on R 2.6.1 running on Fedora 8
(Linux), but I am experiencing the following problems:
-
configure: error: X11 not found but required, configure aborted.
ERROR: configuration failed for package 'rgl'
**
On Sat, Mar 8, 2008 at 5:33 PM, George N. White III
[EMAIL PROTECTED] wrote:
I am trying to install the rgl package on R 2.6.1 running on Fedora 8
(Linux), but I am experiencing the following problems:
-
configure: error: X11 not found but
On Sun, Mar 9, 2008 at 9:10 PM, Gustave Lefou [EMAIL PROTECTED] wrote:
I have another question.
I have seen there is a function called constrOptim in R.
Is it better than optim, for example to optimize a function f of two
parameters belonging to [0,1] and [0,Infinity] ? Do the methods
Dear All,
I have Rcmdr installed on a machine running Fedora 8 (Linux). It works
fine, but I find the fonts of the Script window and of Output window
very small. How can one increase the size of the font use on those
windows?
Thanks in advance,
Paul
] On Behalf Of Paul Smith
Sent: March-10-08 8:20 AM
To: r-help
Subject: [R] Changing font size of Rcmdr (Linux)
Dear All,
I have Rcmdr installed on a machine running Fedora 8 (Linux). It works
fine, but I find the fonts of the Script window and of Output window
very small. How
2008/3/10, Paul Smith [EMAIL PROTECTED]:
On Sun, Mar 9, 2008 at 9:10 PM, Gustave Lefou [EMAIL PROTECTED]
wrote:
I have another question.
I have seen there is a function called constrOptim in R.
Is it better than optim, for example to optimize a function f of two
On Fri, Mar 14, 2008 at 6:42 PM, Hans W Borchers [EMAIL PROTECTED] wrote:
I have some problems, when I try to model an
optimization problem with some constraints.
The original problem cannot be solved analytically, so
I have to use routines like Simulated Annealing or
Sequential
On Sun, Mar 16, 2008 at 7:38 PM, Liviu Andronic [EMAIL PROTECTED] wrote:
I have several problems in using rgl-0.77 (and recent earlier
versions) on Gentoo Linux with a custom-built v. 2.6.22 kernel.
Currently I use R-2.6.1.
When I build rgl,
# R CMD INSTALL
On Wed, Mar 26, 2008 at 1:17 PM, Andreas Klein [EMAIL PROTECTED] wrote:
I have some further problems with modelling an
optimization problem in R:
How can I model some optimization problem in R with a
linear objective function with subject to some
nonlinear constraints?
I would like to
On Wed, Mar 26, 2008 at 7:27 PM, Ala' Jaouni [EMAIL PROTECTED] wrote:
I failed to mention that the X values have to be positive and between 0 and
1.
Use Robert's method, and to do his step 1, use runif (?runif) to get
random numbers from the uniform distribution between 0 and 1.
Paul
Dear All,
I have just updated R to the version 2.6.2 on F8 (with the official F8
rpm). However, when running as root the following command:
update.packages(checkBuilt=T)
I get a bunch of errors like the ones below. Any ideas?
Thanks in advance,
Paul
On Thu, Mar 27, 2008 at 10:20 PM, Marc Schwartz
[EMAIL PROTECTED] wrote:
I have just updated R to the version 2.6.2 on F8 (with the official F8
rpm). However, when running as root the following command:
update.packages(checkBuilt=T)
I get a bunch of errors like the ones below.
On Sat, Mar 29, 2008 at 9:33 PM, Hans W. Borchers [EMAIL PROTECTED] wrote:
Reply to Optimization with constraint on March 14, 2008
One can get an accurate solutons applying the Differential Evolution
algorithm
as implemented in the DEoptim package:
f2 - function(x){
if
Dear All,
I am trying to solve the optimization problem below, but I am always
getting the following error:
Error in optim(rep(20, nvar), f, gr, method = L-BFGS-B, lower = rep(0, :
L-BFGS-B needs finite values of 'fn'
Any ideas?
Thanks in advance,
Paul
a function without a lower bound.
Using the trace facilities of optim() would have got you thereeasily
enough.
On Mon, 31 Mar 2008, Paul Smith wrote:
Dear All,
I am trying to solve the optimization problem below, but I am always
getting the following error:
Error in optim(rep
(x)) - 200*(sum(x)-k)^2
if(!is.finite(r))
r-1e+20 return(r)
}
have a nice day.
On Mon, 31 Mar 2008 12:24:09 +0100 Paul Smith wrote:
Dear All,
I am trying to solve the optimization problem below, but I am always
getting the following error:
Error in optim(rep(20, nvar), f
Dear All,
I tried to download the package Rdonlp2 from the address given at
CRAN Task View: Optimization and Mathematical Programming:
http://arumat.net/Rdonlp2/
However, this link seems to be dead. Any ideas?
Thanks in advance,
Paul
__
Thanks, Mario. With a different browser, it works, but not with Firefox 3.5b4.
Paul
On Sat, Jun 27, 2009 at 7:19 PM, Mario Vallemva...@cscs.ch wrote:
Retry, it works for me.
Ciao!
mario
Paul Smith wrote:
Dear All,
I tried to download the package Rdonlp2 from the address
On Fri, Aug 15, 2008 at 6:15 PM, John Sorkin
[EMAIL PROTECTED] wrote:
Fedora 9
R 2.7.1
I tried to install R on my Linux system using
install.packages(Rcmdr, dependencies=TRUE).
I received many, many, many error messages. I hope someone can suggest a
fix.
The output from warnings()
is
Baltimore VA Medical Center
10 North Greene Street
GRECC (BT/18/GR)
Baltimore, MD 21201-1524
(Phone) 410-605-7119
(Fax) 410-605-7913 (Please call phone number above prior to faxing)
[EMAIL PROTECTED]
Paul Smith [EMAIL PROTECTED] 08/15/08 4:02 PM
On Fri, Aug 15, 2008 at 6:15 PM, John Sorkin
[EMAIL
On Tue, Aug 19, 2008 at 8:35 AM, Chua Siang Li
[EMAIL PROTECTED] wrote:
Hi. I need some advises on how to use R to find pi (i is the index) with
the following objective function and constraint:
max (sum i)[ f(ai, bi, pi) * g(ci, di, pi) * Di ]
s.t. (sum i)[ f(ai, bi, pi) * Di *
On Tue, Aug 19, 2008 at 7:37 PM, Ravi Varadhan [EMAIL PROTECTED] wrote:
The Tango project website (from Brazil) has some R functions to implement
Algencan. I haven't used it, but I would be interested to hear others'
experience if someone has already used it or will be using it.
Ravi,
The
On Tue, Aug 19, 2008 at 8:12 PM, Hans W. Borchers [EMAIL PROTECTED] wrote:
Please have a look at the 'Rdonlp2' package at http://arumat.net/Rdonlp2/.
It provides non-linear optimization with nonlinear constraints.
Notwithstanding, be aware of the following limitation of Donlp2:
If the problem
On Sat, Sep 6, 2008 at 5:10 AM, sudeshna [EMAIL PROTECTED] wrote:
hi im starting with R.have no idea to start...plz help
Search the Internet for online tutorials and/or read an introductory
book (search for them, e.g., on Amazon.Com).
Good luck,
Paul
Dear All,
The function curve() draws the graph of functions from R to R. Is
there some homologous function to curve() to draw functions from R^2
to R?
Thanks in advance,
Paul
__
R-help@r-project.org mailing list
On Tue, Sep 23, 2008 at 6:32 PM, Duncan Murdoch [EMAIL PROTECTED] wrote:
The function curve() draws the graph of functions from R to R. Is
there some homologous function to curve() to draw functions from R^2
to R?
No, you would have to write it yourself. The basic idea is to use outer()
to
On Wed, Sep 24, 2008 at 4:05 AM, Ben Bolker [EMAIL PROTECTED] wrote:
The function curve() draws the graph of functions from R to R. Is
there some homologous function to curve() to draw functions from R^2
to R?
There is a curve3d function in the emdbook package on CRAN.
Thanks, Ben and
Dear All,
I am not sure whether the following can be considered a bug:
x - seq(-1,1,length=20)
y - x
z - matrix(1,20,20)
persp(x,y,z)
Error in persp.default(x, y, z) : invalid 'z' limits
It works with:
persp(x,y,z,zlim=c(0,1.5))
Should not persp set the z limits by default when the matrix
means a 2-D curve will be
extruded along the Y dimension.
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
On Behalf Of Paul Smith
Sent: Wednesday, September 24, 2008 06:20
To: [EMAIL PROTECTED]
Subject: Re: [R] How to draw the graph of f(x,y) = x * y ?
On Wed, Sep
On Tue, Jul 8, 2008 at 6:59 AM, Daren Tan [EMAIL PROTECTED] wrote:
I have a folder full of pngs and jpgs, and would like to consolidate them
into a pdf with appropriate title and labels. Can this be done via R ?
I do not know whether R can do that. However, you can accomplish that
easily with
On Tue, Jul 8, 2008 at 11:28 AM, Kanak Choudhury [EMAIL PROTECTED] wrote:
i have a function like
1+sin(a+bx) where -pi/2=a+bx=pi/2
i made a progrom using constrOptim() function but it is not giving good
result. it depends on the initial value. but when i am doing simulation it
is impossible
On Sun, Jul 20, 2008 at 1:44 PM, David Epstein
[EMAIL PROTECTED] wrote:
Please excuse me for asking such basic questions:
Here is my code
y=c(1.21,0.51,0.14,1.62,-0.8,0.72,-1.71,0.84,0.02,-0.12)
ybar=mean(y)
ll=length(y);
ybarv=rep(ybar,ll)
x=1:ll
plot(x,ybarv,pch=1)
On Sun, Jul 20, 2008 at 11:14 PM, Gabor Grothendieck
[EMAIL PROTECTED] wrote:
Try lattice:
library(lattice)
xyplot(y ~ x, ylim = c(0.5, 0.7), aspect = iso)
Alternatively,
set.seed(42)
x - runif(10)
y - runif(10)
plot(x[(y=0.5) (y=0.7)],y[(y=0.5) (y=0.7)],ylim=c(0.5,0.7),asp=1)
Paul
On Tue, Jul 22, 2008 at 5:44 AM, ascentnet [EMAIL PROTECTED] wrote:
I am trying to access the R2, intercept, and slope out of the summary from an
lm so that I can insert it into a database using RODBC. How can I access
these individually?
Try:
data(swiss)
model - lm(Infant.Mortality ~
On Wed, Apr 2, 2008 at 5:05 PM, [EMAIL PROTECTED] wrote:
hi: you need to give an example and details or
you won't get much response, if any.
Equation e.g. (A, B are known constants):
3log(gamma(x))-log(gamma(x)*gamma(2x))+(x-1)*A+B=0
uniroot() can solve that if you can
/agingandhealth/People/Faculty/Varadhan.html
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On
Behalf Of Paul Smith
Sent: Monday, March 31, 2008 2:25 PM
To: R-help
: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On
Behalf Of Ravi Varadhan
Sent: Wednesday, April 02, 2008 2:03 PM
To: 'Paul Smith'; 'R-help'
Subject: Re: [R] L-BFGS-B needs finite values of 'fn'
Yes, that is very important. If you look at the ratios x[k]/x[k-1], they
are very close
On Sun, Apr 13, 2008 at 12:37 AM, Martin Morgan [EMAIL PROTECTED] wrote:
Hi Ethan --
Use the XML library
library(XML)
url -
'http://www.nascar.com/races/cup/2007/1/data/standings_official.html'
xml - htmlTreeParse(url, useInternal=TRUE)
The previous line retrieves the html and
On Wed, Apr 9, 2008 at 7:37 PM, Ravi Varadhan [EMAIL PROTECTED] wrote:
I have a data file, certain lines of which are character fields. I would
like to skip these rows, and read the data file as a numeric data frame. I
know that I can skip lines at the beginning with read.table and scan,
On Wed, Apr 23, 2008 at 8:51 PM, Kevin Lu [EMAIL PROTECTED] wrote:
I need to find the minimum value of the parameter, s, such that the function
f(s,t) 0 (where -Inf t Inf)
I've looked into optim, constrOptim and others but they don't seem to do
this. Des anyone have some suggestions?
2008/4/25 Radka Pancheva [EMAIL PROTECTED]:
I am trying to estimate the parameters of a bimodal normal distribution
using moments matching, so I have to solve a non-linear system of equations.
How can I solve the following simple example?
x^2 - y^2 = 6
x – y = 3
I heard about
Try to change the initial values of the parameters with, for instance,
p0 - rnorm(2)
But you sure that your system has a solution, Evgeniq?
Paul
2008/4/25 Radka Pancheva [EMAIL PROTECTED]:
Hello Paul,
Thank you for your quick answer. I have tried to use your advice and to
estimate the
On Thu, May 1, 2008 at 12:31 AM, Nelson Castillo [EMAIL PROTECTED] wrote:
Aside from optiming your code by making use of R functions
that use C underneath as much as possible the big difference
between R and Matlab is Matlab's just-in-time compilation of
code. When that was
On Thu, May 22, 2008 at 5:00 PM, Monica Pisica [EMAIL PROTECTED] wrote:
- It seems that it is hard to install correctly under Linux.
Actually, it is quite easy to install R under Linux, at least in some
distributions. For instance, on Fedora:
yum install R R-devel
and that is it.
Paul
On Fri, May 30, 2008 at 12:04 PM, threshold [EMAIL PROTECTED] wrote:
Thanks for all your replies and sorry for a negligence in my examples. They
are very simplified to reflect very roughly the structure of the case I deal
with, which is too complicated to be quoted here.
What I deal with is:
On Mon, Jun 2, 2008 at 11:59 AM, Blubbele [EMAIL PROTECTED] wrote:
Thanks but it swaps in both cases only the data:
FemMal_88[c(61,62)]=FemMal_88[c(62,61)]
FemMal_88[,c(61,62)]=FemMal_88[,c(62,61)]
The following works:
d - data.frame(a=c(1,2),b=c(3,4))
d - d[,c(2,1)]
Paul
On Mon, Jun 2, 2008 at 1:04 PM, Birgitle [EMAIL PROTECTED] wrote:
Thanks Paul.
I am not sure if I understood well, but when I do it then I have only two
columns left:
L3 - LETTERS[1:3]
(d - data.frame(cbind(x=1, y=1:10, z=11:20), fac=sample(L3, 10,
replace=TRUE)))
x y z fac
1 1 1
On Mon, Jun 2, 2008 at 4:31 PM, François Aucoin [EMAIL PROTECTED] wrote:
I would like to solve the following function in R:
G - function(k) (2*(1 - k)*(1 + 2*k)^.5)/(1+3*k)
I want to be able to find k for a given G
Consider G(k)-g. With plot look for intervals where the roots lie in.
On Fri, Jun 6, 2008 at 10:30 PM, RobertsLRRI [EMAIL PROTECTED] wrote:
when I load my data file in txt format into the R workstation I lose about
6000 rows, this is a problem. Is there a limit to the display capabilities
for the workstation? is all the information there and I just can't see
On Sun, Jun 8, 2008 at 9:33 AM, Peter Dalgaard [EMAIL PROTECTED] wrote:
I'm in need of a version of R that will run on fedora 9 and haven't been
able
to find one. I need this in order to run Bioconductor. Any advice?
Why not say (as root)
yum install R
?
Worked for me. The point is
On Sun, May 3, 2009 at 6:36 PM, Wensui Liu liuwen...@gmail.com wrote:
Sometimes, it is too costly to read the whole data file into R.
I am looking for solution in scan() and read.Lines() but don't they work.
Try the following (assuming a 3 columns data file):
mydata -
Dear All,
Where can one find the code of the max() function? Is that written in C?
Thanks in advance,
Paul
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide
On Mon, May 4, 2009 at 7:47 PM, David Winsemius dwinsem...@comcast.net wrote:
Where can one find the code of the max() function? Is that written in C?
pages 43-54 of:
http://cran.r-project.org/doc/Rnews/Rnews_2006-4.pdf
... is an article by Uwe Ligges on accesssing source code.
Thanks,
Dear All,
Perhaps, what I am asking is impossible, but I am asking it anyway.
I have got several pdf files with rows of colored rectangles: red
rectangles should be read as 0; green rectangles as 1. No other color
exists. Is there some way to have R reading the colored rectangles to
a matrix or
Thanks, Baptiste and Zeljko. I am attaching here an example of the
picture of the rectangles.
Paul
On Tue, May 12, 2009 at 1:23 PM, baptiste auguie ba...@exeter.ac.uk wrote:
Depending on the nature of your pdf file, it may be possible to use
the grImport package. I've never used it before,
On Tue, May 12, 2009 at 2:35 PM, Zeljko Vrba zv...@ifi.uio.no wrote:
Aha, so you DON'T have only red and green rectangles in the picture, there is
also white in between, and some pale delimiter lines. Nevertheless, both
things ease the job slightly, and the approach I described should work.
On Thu, Jun 11, 2009 at 9:56 PM, Brecknock, Peterpeter.breckn...@bp.com wrote:
Apologies if this is not the correct list for this question.
The Rglpk package offers the following example in its documentation
library(Rglpk)
## Simple mixed integer linear program.
## maximize: 3 x_1 + 1 x_2 +
On Nov 16, 2007 7:27 PM, kalin lagno [EMAIL PROTECTED] wrote:
Which R function I should use to obtain determinant of a matrix with real(and
complex) numbers?
For real matrices:
?det
Paul
__
R-help@r-project.org mailing list
Dear All,
I would like to export, as a pdf file, a plot with the LaTeX font
lmodern as the font of my graph. Could somebody please help me?
Thanks in advance,
Paul
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
Dear All,
Consider the following code:
plot(0,0)
text(0,0.5,expression(italic(theta)))
I would like to get theta in italic, but I always get it upright. Any
suggestions?
Thanks in advance,
Paul
__
R-help@r-project.org mailing list
On Nov 18, 2007 8:04 PM, Paul Smith [EMAIL PROTECTED] wrote:
I would like to export, as a pdf file, a plot with the LaTeX font
lmodern as the font of my graph. Could somebody please help me?
I have tried the following but with no success:
pdf(file=myplot.pdf,family=ComputerModern)
Error
Dear All,
Can R produce dot plots like the one of the following picture:
http://en.wikipedia.org/wiki/Image:Dotplot_of_random_values.png
?
I have tried dotchart, but no success.
Thanks in advance,
Paul
__
R-help@r-project.org mailing list
On Nov 24, 2007 9:57 PM, jim holtman [EMAIL PROTECTED] wrote:
Does this give you want you want?
x - sample(1:10)
plot(rep(1:10, x), unlist(sapply(x, seq)), pch=19, cex=3, yaxt='n')
On Nov 24, 2007 4:26 PM, Paul Smith [EMAIL PROTECTED] wrote:
Dear All,
Can R produce dot plots like
On Nov 24, 2007 10:11 PM, A. Beaujean [EMAIL PROTECTED] wrote:
?stripchart shows the at command
e.g.,
stripchart(data, method=stack, pch=16, at=0)
That is perfect! Thanks.
Paul
__
R-help@r-project.org mailing list
Dear All,
With plot, one can use to the option 'axes=F' to remove axes. I have
tried it with stripchart, but no success. How can one then customize
the x-axis with stripchart?
Thanks in advance,
Paul
__
R-help@r-project.org mailing list
1 - 100 of 183 matches
Mail list logo