discard zeros.
> -Original Message-
> From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org]
> On Behalf Of Rui Barradas
> Sent: Friday, October 12, 2012 18:04
> To: wwreith
> Cc: r-help@r-project.org
> Subject: Re: [R] Autofilling a large matrix in R
>
Hello,
Something like this?
g[rowSums(g) == 100, ]
Hope this helps,
Rui Barradas
Em 12-10-2012 15:30, wwreith escreveu:
I wish to create a matrix of all possible percentages with two decimal place
percision. I then want each row to sum to 100%. I started with the code
below with the intent t
next row
> until they add up to 100%, etc.?
> Thanks.
>
>
>
>
> From: wwreith
> To: r-help@r-project.org
> Sent: Friday, October 12, 2012 10:30 AM
> Subject: [R] Autofilling a large matrix in R
>
> I wish to create a matrix of
2 10:30 AM
Subject: [R] Autofilling a large matrix in R
I wish to create a matrix of all possible percentages with two decimal place
percision. I then want each row to sum to 100%. I started with the code
below with the intent to then subset the data based on the row sum. This
works great for 2 or 3 co
I wish to create a matrix of all possible percentages with two decimal place
percision. I then want each row to sum to 100%. I started with the code
below with the intent to then subset the data based on the row sum. This
works great for 2 or 3 columns, but if I try 4 or more columns the number of
5 matches
Mail list logo