Hi Ragia,
I may be missing your point, but try the "htmlize" function in the prettyR
package. This creates an HTML file containing both the text output and
images from an R script.
Jim
On Fri, Jan 1, 2016 at 11:46 AM, Ragia Ibrahim wrote:
> Dear group
> I have a script that prints data frames a
Does what? You said you already have a script.
**If** you want to program it as a function, then I suggest that you
do some homework and go through an R tutorial, e.g. the "Intro to R"
that ships with R or one of the many available on the web.
If that is not what you mean, then clarify.
Cheers,
Dear group
I have a script that prints data frames and plot using ggplot 2 while running,
how can I do this
thanks in advance
Ragia
__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.et
> On Dec 31, 2015, at 11:16 AM, Abram Wooten via R-help
> wrote:
>
> Hello,
>
> I am new to R and I am having trouble adding an exponent to my problem. For
> instance,
>> mat5 <-matrix(c(0.5,0.5,0.25,0.75),2,byrow=T)
>> mat6 <-matrix(c(0.5,0.5,0.25,0.75),2,byrow=T)
>> mat5%^%2
> Error: could
Hi Steve,
Maybe something like this:
Sconc<-matrix(c(1450,1800,1840,1820,1860,1780,1760,1800,1900,
1770,1790,1780,1850,1760,1450,1710,1575,1475,1780,1790,
1780,1450,1790,1800,1,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0),
24,2)
hist(Sconc[,1],breaks=c(1450,1550,1650,1750,1900))
abline(v=1450
Well, all of the solutions proposed are a bit tricky in that the
matrix must be "constructed" by hand. They are also reinventing
wheels. What I think you really want is the kronecker product, which
is the matrix operation that does exactly what you want. e.g.
A <- matrix(1:4, nr=2)
to create a ne
On 31/12/15 23:20, Steven Stoline wrote:
Dear All:
I need helps with creating histograms for data that include left
censored observations.
Here is an example of left censored data
*Sulfate.Concentration*
<-matrix(c(1450,1800,1840,1820,1860,1780,1760,1800,1900,1770,1790,
1780,1850,1760,1450,1
> On Dec 31, 2015, at 1:12 PM, David Winsemius wrote:
>
>>
>> On Dec 31, 2015, at 11:16 AM, Abram Wooten via R-help
>> wrote:
>>
>> Hello,
>>
>> I am new to R and I am having trouble adding an exponent to my problem. For
>> instance,
>>> mat5 <-matrix(c(0.5,0.5,0.25,0.75),2,byrow=T)
>>> m
Something like:
A <- matrix(c(1,2,3,4),2,2)
A
B <- matrix(rep(A, 4), nrow=2)
B
C <- do.call(rbind, lapply(1:8, function(x) B))
C
On Thu, Dec 31, 2015 at 12:28 PM, Kathryn Lord
wrote:
> Dear R users,
>
> Suppose that I have a matrix A
>
> A <- matrix(c(1,2,3,4),2,2)
>> A
> [,1] [,2]
> [1,
Hello,
I am new to R and I am having trouble adding an exponent to my problem. For
instance,
> mat5 <-matrix(c(0.5,0.5,0.25,0.75),2,byrow=T)
> mat6 <-matrix(c(0.5,0.5,0.25,0.75),2,byrow=T)
> mat5%^%2
Error: could not find function "%^%"
I unsure on weather I should square mat5 or use the two m
> On Dec 31, 2015, at 12:28 PM, Kathryn Lord wrote:
>
> Dear R users,
>
> Suppose that I have a matrix A
>
> A <- matrix(c(1,2,3,4),2,2)
>> A
> [,1] [,2]
> [1,]13
> [2,]24
>
> With this matrix A, I'd like to create bigger one, for example,
>
> [,1] [,2] [,3] [,4] [,5
A <- matrix(c(1,2,3,4),2,2)
B <- matrix(A, nrow=14, ncol=14)
> B
[,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [,11] [,12] [,13] [,14]
[1,]131313131 3 1 3 1 3
[2,]242424242 4 2 4
Dear R users,
Suppose that I have a matrix A
A <- matrix(c(1,2,3,4),2,2)
> A
[,1] [,2]
[1,]13
[2,]24
With this matrix A, I'd like to create bigger one, for example,
[,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [,11] [,12] [,13]
[,14]
[1,]1313
> On Dec 30, 2015, at 11:26 PM, SHIVI BHATIA
> wrote:
>
> Hi Duncan,
> Please find the dput from the data.
>
> ab<-read.csv("collection_last.csv",header=TRUE)
> y<-ab[1:10,]
>
This is (possibly) partial output from a dput call. Unable to repair at any
rate.
>
> ab<- "2,458", "2,461", "2,46
Try
d= data[ ,i]
instead of d= data[i]
in your function. If that doesn't help, I think we would have to know
more about the structure of your data.
-- Bert
Bert Gunter
"The trouble with having an open mind is that people keep coming along
and sticking things into it."
-- Opus (aka Berkeley
Shivi,
It looks like you have copied and pasted with errors. When you use dput() on a
dataframe, it will output a list (see example that follows). I think you have
cut off the beginning of the output and have manually added the assignment
“ab<-“. Also it is clear that the read.csv is interpreti
I am trying to generate a confidence interval for the statistic arpt (at
risk of poverty threshold generated with the package leaken) using the
package boot.
This is my temptative script (where XH090 and DB030 and w are variables
of an attached dataframe):
> arpt.boot <- function(data,i){
> d
Dear All:
I need helps with creating histograms for data that include left censored
observations.
Here is an example of left censored data
*Sulfate.Concentration*
<-matrix(c(1450,1800,1840,1820,1860,1780,1760,1800,1900,1770,1790,1780,1850,1760,1450,1710,1575,1475,1780,1790,1780,1450,1790,1800,
Hi all,
In help(unname), for the "force" argument, it states that
"if true, the dimnames (names and row names) are removed even from
data.frames."
However, when I use unname() to remove all the names from mtcars, it fails.
> unname(mtcars, force = TRUE)
Error in `dimnames<-.data.frame`(`*tmp*`,
Hi Duncan,
Please find the dput from the data.
ab<-read.csv("collection_last.csv",header=TRUE)
y<-ab[1:10,]
ab<- "2,458", "2,461", "2,462", "2,463", "2,464", "2,465", "2,468",
"2,469", "2,470", "2,473", "2,474", "2,475", "2,476", "2,477",
"2,478", "2,479", "2,480", "2,483", "2,484,267", "2,485",
Anindya Sankar Dey wrote/hat geschrieben on/am 30.12.2015 07:35:
Hi All,
The fmsb package has a function called Variance Inflation Factor and it
states the definition of the function as follows:-
"To evaluate multicolinearity of multiple regression model, calculating the
variance inflation fa
21 matches
Mail list logo