Re: [R] more boa plots questions

2011-03-03 Thread emj83
Can anyone help? Thanks in advance Emma -- View this message in context: http://r.789695.n4.nabble.com/more-boa-plots-questions-tp3330312p016.html Sent from the R help mailing list archive at Nabble.com. __ R-help@r-project.org mailing list

Re: [R] boa library and plots

2011-03-01 Thread emj83
Many thanks for your response, and I am sorry I did not post correctly. I have found dev.copy2eps() useful. Emma -- View this message in context: http://r.789695.n4.nabble.com/boa-library-and-plots-tp3322508p3330299.html Sent from the R help mailing list archive at Nabble.com.

[R] more boa plots questions

2011-03-01 Thread emj83
I have MCMC output chains A and B for example, I want to produce trace plots for them using the boa command line... #loads boa boa.init() #reads in chains boa.chain.add(boa.importMatrix('A'), 'A') boa.chain.add(boa.importMatrix('B'), 'B') #plot trace plot problems arise here! I know I can get

[R] boa library and plots

2011-02-24 Thread emj83
Hi, I would like to save the plots produced by boa into postscript files in R. I am struggling- can anyone advise? Thanks Emma -- View this message in context: http://r.789695.n4.nabble.com/boa-library-and-plots-tp3322508p3322508.html Sent from the R help mailing list archive at Nabble.com.

[R] intervals command

2011-02-22 Thread emj83
Hi, I am fitting a random effects model and I am interested in the 95% confidence interval of the variance components. When I use the intervals() command it gives me the 95% confidence interval of the standard deviation. Is there anyway of getting the 95% confidence interval of the variance?

[R] Changing a logical matrix into a numeric matrix

2011-01-10 Thread emj83
Hi, I would like to turn my TRUE/FALSE matrix into a 1/0 matrix (i.e. True=1 and False=0) [,1] [,2] [,3] [1,] TRUE FALSE FALSE [2,] TRUE TRUE FALSE [3,] TRUE TRUE TRUE [,1] [,2] [,3] [1,]10 0 [2,]11 0 [3,]11 1 Is there a quick

Re: [R] Changing a logical matrix into a numeric matrix

2011-01-10 Thread emj83
Thanks for everyone's suggestionsI didn't realise it was so straightforward- thanks for teaching me new tricks! Emma -- View this message in context: http://r.789695.n4.nabble.com/Changing-a-logical-matrix-into-a-numeric-matrix-tp3206797p3206844.html Sent from the R help mailing list

[R] Summing over specific columns in a matrix

2011-01-07 Thread emj83
Hi, I would like to sum some specific columns in my matrix- for example, my matrix looks like this: [,1] [,2] [,3] [,4] [,5] [1,]1 NA NA NA NA [2,]21 NA1 NA [3,]321 21 [4,]432 32 [5,] NA NA NA43 [6,] NA

[R] How to join matrices of different row length from a list

2011-01-06 Thread emj83
Hi, I have several matrix in a list, for example: e [[1]] [,1] [,2] [1,]13 [2,]24 [[2]] [,1] [,2] [1,]14 [2,]25 [3,]36 [[3]] [,1] [,2] [1,]21 I would like to join them by column i.e. [,1] [,2] [,3] [,4][,5] [,6] [1,]1

Re: [R] How to join matrices of different row length from a list

2011-01-06 Thread emj83
Excellent- that is just what I need. Thank you so much for your prompt help, Emma -- View this message in context: http://r.789695.n4.nabble.com/How-to-join-matrices-of-different-row-length-from-a-list-tp3177212p3177252.html Sent from the R help mailing list archive at Nabble.com.

[R] Matrix Manipulation

2010-11-04 Thread emj83
Hi, Is there a quick way to go from this matrix: A [,1] [,2] [,3] [1,]111 [2,]222 [3,]333 [4,]444 [5,]5 NA5 [6,] NA NA6 [7,] NA NA NA to this matrix: B [,1] [,2] [,3] [1,]1 NA NA [2,]2 NA1 [3,]

Re: [R] Matrix Manipulation

2010-11-04 Thread emj83
Many thanks-its worked a treat :-) Emma -- View this message in context: http://r.789695.n4.nabble.com/Matrix-Manipulation-tp3027266p3027307.html Sent from the R help mailing list archive at Nabble.com. __ R-help@r-project.org mailing list

[R] Sample in R

2010-10-19 Thread emj83
Hi, Please can someone tell me if using sample() in R is actually a quick way of doing the Inverse Transform Sampling Method? Many thanks Emma -- View this message in context: http://r.789695.n4.nabble.com/Sample-in-R-tp3001818p3001818.html Sent from the R help mailing list archive at

Re: [R] Between-group variance from ANOVA

2009-08-25 Thread emj83
can anyone advise me please? emj83 wrote: I have done some ANOVA tables for some data that I have, from this I can read the within-group variance. can anyone tell me how i may find out the between-group variance? Thanks Emma -- View this message in context: http://www.nabble.com

Re: [R] Between-group variance from ANOVA

2009-08-25 Thread emj83
~ group, data=TDat)) Regards, Mark. emj83 wrote: can anyone advise me please? emj83 wrote: I have done some ANOVA tables for some data that I have, from this I can read the within-group variance. can anyone tell me how i may find out the between-group variance? Thanks Emma

[R] Between-group variance from ANOVA

2009-08-13 Thread emj83
I have done some ANOVA tables for some data that I have, from this I can read the within-group variance. can anyone tell me how i may find out the between-group variance? Thanks Emma -- View this message in context:

[R] numbers loop in R

2009-04-17 Thread emj83
I would like to create a matrix in R that looks similar to this: [,1] [,2] [,3] [,4] [1,] NaN 1 2 3 [2,] NaN 1 2 4 [3,] NaN 1 2 5 [4,] NaN 2 3 4 [5,] NaN 2 3 5 [6,] NaN345 I have the loop below: where A for example is 5 matrixx-function(A){

[R] cbind

2009-04-14 Thread emj83
I have a list of numbers with NAs as below: A[,1] [1] NA NA NA NA NA NA NA NA NA NA NA NA NA NA NA NA NA NA [19] NA NA NA NA NA NA NA NA NA NA NA NA NA NA NA NA NA NA [37] NA NA NA NA NA NA NA NA NA NA NA NA NA NA NA NA NA NA [55] NA

[R] naming vectors/ matrices in R

2009-03-31 Thread emj83
I would like to create a series of vectors in a loop and name them with letters. I know the command letters gives me the 26 letters of the alphabet. For example, I have a dataframe, called A, with 6 columns. B-length(A) C-letters(1:B) [1] a b c d e f I would like to extract the first letter

[R] matching vectors

2009-03-17 Thread emj83
I have two numerical vectors; hun2 is a subset of hun1: hun1 [1] 147 198 141 170 184 136 150 134 144 161 124 103 107 110 121 79 106 51 [19] 102 109 52 71 52 80 95 78 75 96 101 107 107 80 71 49 71 64 [37] 58 68 75 85 55 52 70 90 98 90 100 98 74 78 60 69 106 103

[R] pairs of numbers

2009-03-13 Thread emj83
Hi, I have two lists of numbers which are both 1,2,3,4. I would like to combine pairs so that I have: 1,2 1,3 1,4 2,3 2,4 3,4. I know that expand.grid() can give me all combinations of pairs. Any suggestions would be much appreciated. Emma -- View this message in context:

Re: [R] pairs of numbers

2009-03-13 Thread emj83
I have solved my problem using: x-1:4 x [1] 1 2 3 4 combn(x,2) [,1] [,2] [,3] [,4] [,5] [,6] [1,]111223 [2,]234344 Thanks Emma emj83 wrote: Hi, I have two lists of numbers which are both 1,2,3,4. I would like to combine pairs so

[R] auto.arima in forecasting package

2009-02-18 Thread emj83
I am using auto.arima to find the best arima model but am a little confused by the output. I want to choose the best model using the BIC criteria. This is my code (straightforward where a is the data)

[R] ARIMA models

2009-02-17 Thread emj83
is there some sort of R function which can advise me of the best ARIMA(p,q,r) model to use based on the Schwarz criterion e.g for e.g p=0-5, q =0, r=0-5 or for example p+r 5??? or is this something I will have to write my own code for? Thanks Emma -- View this message in context:

[R] selecting parts of a table

2009-01-14 Thread emj83
I have a dataframe called Match with two columns: position and tvalue. I would like to select the parts of the dataframe that have a position 10 but 50 and tvalues 3.5 as a new stand alone dataframe. Could anyone help me with how to do this? Thanks Emma -- View this message in context:

[R] systematically matching the numbers in two sequences

2008-12-05 Thread emj83
I am having trouble writing a code for matching two pairs of sequences with differing lengths: for example sequence1= 1,2,3,4,5,6,7 sequence2=1,2,3,4,5,6,7,8,9,10 I want to create several new pairs of sequences in several dataframes such that: 1st dataframe is 1,10 (start of sequence1, end of

[R] systematically matching the numbers in two sequences

2008-12-05 Thread emj83
I am having trouble writing a code for matching two pairs of sequences with differing lengths: for example sequence1= 1,2,3,4,5,6,7 sequence2=1,2,3,4,5,6,7,8,9,10 I want to create several new pairs of sequences in several dataframes such that: 1st dataframe is 1,10 (start of sequence1, end of

[R] Function output difficulties

2008-12-03 Thread emj83
is there anyway for some parts of the function output to not be returned, even if the output has been used to calculate a further part of the function? i have tried invisible() to no avail. Thanks Emma -- View this message in context: