A couple of questions in connection with using .csv format to include
data in a package:
First, the background. The data() function loads data from .csv
(comma-separated values) files using
read.table(..., header = TRUE, sep = ;)
But ?read.table says
## To write a CSV file for input
A couple of questions in connection with using .csv format to include
data in a package:
First, the background. The data() function loads data from .csv
(comma-separated values) files using
read.table(..., header = TRUE, sep = ;)
But ?read.table says
## To write a CSV file for input
Is there a function that would allow me to create a line graph of some central
tendency, such as mean, with limits indicated by a vertical line at each data point,
i.e. SD? It's a fairly common type of graphic, but in looking through examples I have
been able to find, I have found no function
On Wed, Jul 09, 2003 at 10:53:27AM +0100, David Firth wrote:
First, the background. The data() function loads data from .csv
(comma-separated values) files using
read.table(..., header = TRUE, sep = ;)
But ?read.table says
## To write a CSV file for input to Excel one might use
I had considered using arrows or line segments to write my own function, but I though
that someone might have done it before me. Thanks to all for their rapid response.
The graphics I need can be generated using plotmeans in the gregmisc package.
Harvey
-Original Message-
Is there a command similar to dim for lists, so that one can know how
many elements it stores?
Is it possible to add elements to a list once it has been constructed?
Thanks in advance,
Aurora
__
[EMAIL PROTECTED] mailing list
my.list-list(a=1,b=2)
length(my.list)
[1] 2
my.list$c-3
my.list[[length(my.list)+1]]-4
my.list
$a
[1] 1
$b
[1] 2
$c
[1] 3
[[4]]
[1] 4
HTH
Thomas
---
Thomas Hotz
Research Associate in Medical Statistics
University of Leicester
United Kingdom
Department of Epidemiology and Public Health
Dear r-helpers!
I have trouble reading data from an Oracle data base using
RODBC Version 1.0-3,
R Version 1.7.1,
Windows XP,
Oracle8 ODBC Driver Version 8.1.6.4.0:
library(RODBC)
channel - odbcConnect(dsn=PAV32, case=oracle, believeNRows=FALSE)
# ok, this was succesful
x - sqlTables(channel)
Why is linear regression not applicable? Your answer to this question
might help someone answer your initial question below.
spencer graves
Ghosh Mini wrote:
Dear R users,
I have complete data of some station (near by) and incomplete data of
desired station. I want to construct the complete
Hi
I am struggling in finding a way to sort columns in a matrix. Can anyone help me,
please?
Thanks a lot,
David
__
[EMAIL PROTECTED] mailing list
https://www.stat.math.ethz.ch/mailman/listinfo/r-help
On Wed, Jul 09, 2003 at 05:39:31PM +0200, David Andel wrote:
Hi,
if you want to sort in alphabical order the columns of the matrix you colud do this
aaa - aaa[,sort(colnames(aaa))]
Is it what you want?
HIH,
Stefano
Hi
I am struggling in finding a way to sort columns in a matrix. Can
Alternatively, if you want to sort first on aaa$a and second on aaa$b,
then try the following:
aaa[order(aaa$a, aaa$b),]
hope this helps. spencer graves
Stefano Calza wrote:
On Wed, Jul 09, 2003 at 05:39:31PM +0200, David Andel wrote:
Hi,
if you want to sort in alphabical order the columns
On Wed, Jul 09, 2003 at 09:10:53AM -0700, Spencer Graves wrote:
Of course! I guess I misunderstood the question!
Stefano
Alternatively, if you want to sort first on aaa$a and second on aaa$b,
then try the following:
aaa[order(aaa$a, aaa$b),]
hope this helps. spencer graves
Stefano
Dear list,
How can one from within a function act
on these variables (outside a function)
that were given as arguments.
If I have e.g. this beginning of a function:
foo - function(tiro){
app.tiro - 3 * tiro
[...]
}
How can I from within the curly brackets
e.g. concatenate the app.tiro to
the
hi all,
I am using optim. I am getting the following error message:
Error in optim(par = start.vals[, h], fn = post.func.pois, gr = post.grad.
pois, :
L-BFGS-B needs finite values of fn
If I look at optim typing ' optim' it seems that the error comes from
inside .Internal(optim), so I
foo - function(tiro){
+ tiro - c(tiro, 3 * tiro)
+ tiro
+ }
foo(2)
[1] 2 6
Is this what you want?
spencer graves
Tobias Verbeke wrote:
Dear list,
How can one from within a function act
on these variables (outside a function)
that were given as arguments.
If I have e.g. this beginning of a
Hi:
I am using R 1.7.0 on Windows. I am having trouble getting outer to
work on one of my functions. Here is a simple example illustrating my
problem:
b1 - c(1.2,2.3)
b2 - c(0.5,0.6)
x - c(3e+01, 1e+02, 3e+02, 5e+02, 1e+03, 1e+04, 1e+05, 1e+06)
y - c(2,4,2,5,2,3,1,1)
n -
Edoardo Airoldi wrote:
hi all,
I am using optim. I am getting the following error message:
Error in optim(par = start.vals[, h], fn = post.func.pois, gr =
post.grad.
pois, :
L-BFGS-B needs finite values of fn
If I look at optim typing ' optim' it seems that the error comes from
Thanks to all of you for your answers,
The situation I was dangerously trying
to cope with was an incomplete life table,
with incomplete ages and incomplete survivors.
This is the table I want to complete using
a Gompertz function to estimate mortality
at high ages:
agelx
1 75 53803
2 80
On Wed, 9 Jul 2003 15:33:12 -0400, Edoardo Airoldi
[EMAIL PROTECTED] wrote :
hi all,
I am using optim. I am getting the following error message:
Error in optim(par = start.vals[, h], fn = post.func.pois, gr = post.grad.
pois, :
L-BFGS-B needs finite values of fn
If I look at
Have you tried:
outer(b1,b2,FUN=bpllkd,x=x,y=y,n=n)
I don't think outer quite knows what to do with x, y, n). However,
x=x1, y=y1, n=n1) clearly tells outer to pass the object x1 to the
argument x of function bpllkd, etc.
hope this helps. spencer graves
p.s. I was just bitten by that
On Wed, 09 Jul 2003 15:33:11 -0400, Ravi Varadhan [EMAIL PROTECTED]
wrote :
Hi:
I am using R 1.7.0 on Windows. I am having trouble getting outer to
work on one of my functions.
Most likely the problem is that the function you give doesn't work on
array arguments. Your function needs to take
Favete linguis...
Thanks,
Tobias
__
[EMAIL PROTECTED] mailing list
https://www.stat.math.ethz.ch/mailman/listinfo/r-help
On Wed, 09 Jul 2003 16:09:24 -0400, Duncan Murdoch [EMAIL PROTECTED]
wrote :
Anything that's called by .Internal is C or Fortran code.
Whoops, .Internal would only call C. Fortran can't handle the R
objects. The C code might call some Fortran to do the work.
Duncan Murdoch
Apologies for cross posting
-
CART Data Mining'04: First International CART(R) Conferences
Focusing on the Data Mining technology of
Leo Breiman, Jerome Friedman, Richard Olshen, Charles Stone
(CART, MARS(R),
gompertz.estimates - function(age, surv){
...
app.age - ageseq[1:length(l.est)]
list(app.age = app.age, l.est = round(l.est, digits=0))
}
The components in the list are the things I
would like to add to the columns in my incomplete
life table.
The way I would do this is by adding
26 matches
Mail list logo