Displaying 4 results from an estimated 4 matches for "diag2".
Did you mean:
diag
2012 Nov 06
1
pivot table
Hello,
I have a data which looks like below: Some of the patients have multiple diagnosis.
ID(200 patients) Diag (100 unique Diag-200 in general) Proc (50 uniqe Proc) DOB (200) Gender (200)
a daig1
b diag2
c diag1
I want to reformat this data to :
ID diag1 diag 2 diag 3.. diagx proc1 proc2 proc3... procx DOB Gender
a1011 20F
Thanks a lot for your help and time.
Best,Farnoosh Sheikhi
[[alternative HTML version deleted]]
2015 May 05
3
Why is the diag function so slow (for extraction)?
Looks like the c(x)[...] bit used to be as.matrix(x)[...]. Not sure
why the change was made many years ago, but this was before names were
handled explicitly. It would definitely be better to not force the
duplicate, at least in the case where we are sure c() and [ would not
dispatch.
Best,
luke
On Mon, 4 May 2015, peter dalgaard wrote:
>
>> On 04 May 2015, at 19:59 , franknarf
2015 May 07
0
Why is the diag function so slow (for extraction)?
Is it possible to replace c() with .subset()? Example below
####
####
library(microbenchmark)
diag2 <- function(x,nrow, ncol){
if (is.matrix(x)) {
if (nargs() > 1L)
stop("'nrow' or 'ncol' cannot be specified when 'x' is a matrix")
if ((m <- min(dim(x))) == 0L)
return(vector(typeof(x), 0L))
# replace this part
y <- .subset...
2009 Mar 05
2
identify() and postscript output
.... Why? Is there a workaround?
library(vcd)
data(Arthritis)
# define Better
Arthritis$Better <- Arthritis$Improved > 'None'
arth.mod1 <- glm(Better ~ Age + Sex + Treatment , data=Arthritis,
family='binomial')
library(car)
# influence plot
#postscript(file="arthritis-diag2.eps", paper="special", height=6,
width=6, onefile=TRUE, horizontal=FALSE)
influencePlot(arth.mod1, main="Arthritis data: influencePlot")
#dev.off()
-Michael
--
Michael Friendly Email: friendly AT yorku DOT ca
Professor, Psychology Dept.
York University Voice:...