Is this a Windows system behind a firewall?
Can you reach the CRAN mirrors directly from Internet Explorer?
If yes to both, then you need to use
setInternet2(TRUE)
before doing the package installations from the RConsole menu.
See the Windows FAQ and the ?setInternet2 for more details.
On Thu,
On 09/16/2010 04:42 PM, Ben Bolker wrote:
> Jorge Nieves moorecap.com> writes:
>
>>
>>
>> Hi,
>>
>> We have some tight controls in our systems and I am having difficulty
>> downloading/upgrading R packages. The IT department will configure our
>> system to let me download packages from two or th
Jorge Nieves moorecap.com> writes:
>
>
> Hi,
>
> We have some tight controls in our systems and I am having difficulty
> downloading/upgrading R packages. The IT department will configure our
> system to let me download packages from two or three R depositories.
> How do I find out what the I
Hi,
We have some tight controls in our systems and I am having difficulty
downloading/upgrading R packages. The IT department will configure our
system to let me download packages from two or three R depositories.
How do I find out what the IP address of the R depositories are so that
I can sele
On Wednesday, June 17, 2009 3:33 PM, edwin wrote:
> Sorry, David has just told my that it was a mistake in my
> example (Thanks David). I had a wrong idea. The right idea is:
> make a ip range, when the number increament without an gap (and
> with maximum number: 255, see example down).
> In
Perhaps it would help to remember that dotted quad notation is
shorthand for an integer value. If an IP address is a.b.c.d, you can
also represent it as a*16777216 + b*65536 +c*256 +d.
If you can convert IP addresses to and from integers then it should be
trivially easy to find the bounds of the
Hi all,
Sorry, David has just told my that it was a mistake in my example (Thanks
David). I had a wrong idea.
The right idea is: make a ip range, when the number increament without an gap
(and with maximum number: 255, see example down).
In case my initial example would be:
> 162.131
Hi Peter,
I hope you could help. I am stuck with this. The last problem I have is:
I have table like:
id rank color status ip
138 29746 yellow yes 162.131.58.1
138 29746 yellow yes 162.131.58.2
138 29746 yellow yes 162.131.58.3
138 29746 yellow yes 162.131.58.4
138 29746 yellow yes 162.131.
Thank you Peter,
This solved the problem.
> edw...@web.de wrote:
> > Hi,
> >
> >
> > Unfortunately, they can't handle NA. Any suggestion? Some row for Ip
> > don't have ip address. This cause an error/ wrong result.
>
> A quick fix could be to substitute "..." or "0.0.0.0" for the "NA"
> entries
Suggest you be more specific. The solution I posted does handle missing values
sorting them to the beginning:
> Lines <- "id rank color status ip
+ 138 29746 yellow no 162.131.58.26
+ 138 29746 red yes 162.131.58.16
+ 138 29746 blue yes 162.131.58.10
+ 138 29746 red no 162.131.58.17
+ 138 297
edw...@web.de wrote:
> Hi,
>
>
> Unfortunately, they can't handle NA. Any suggestion? Some row for Ip
> don't have ip address. This cause an error/ wrong result.
A quick fix could be to substitute "..." or "0.0.0.0" for the "NA"
entries. (Use something like
ipch <- as.character(df$ip)
ipch[is.n
Hi,
Unfortunately, they can't handle NA. Any suggestion? Some row for Ip don't have
ip address. This cause an error/ wrong result.
Eddie
> library(gsubfn)
> library(gtools)
> library(rbenchmark)
>
> n <- 1
> df <- data.frame(
> a = rnorm(n),
> b = rnorm(n),
> c = rnorm(n),
> ip = r
Feel free to use my code however you want. If you put in a package I
prefer an LGPL license, but not required. See R documentation on how
to create a package.
-H
On Mon, Jun 1, 2009 at 9:00 AM, edwin wrote:
>
> Maybe you can make a package for something like this. (IP sort,etc). Like in
> Perl
Maybe you can make a package for something like this. (IP sort,etc). Like in
Perl, there is a module called Sort::Key::IPv4
I think, not only me has the same problem for sorting e.g IP?
Eddie
> Not really, just the old saying that any piece of code can be made
> twice as fast (which often holds
wow =P
Thank you guys. I will use the hb2 , because it is the fastest one.
Eddie
> wow! :)
>
> vQ
>
> Henrik Bengtsson wrote:
> > library(gsubfn)
> > library(gtools)
> > library(rbenchmark)
> >
> > n <- 1
> > df <- data.frame(
> > a = rnorm(n),
> > b = rnorm(n),
> > c = rnorm(n),
> >
Not really, just the old saying that any piece of code can be made
twice as fast (which often holds true recursively). /Henrik
On Sun, May 31, 2009 at 1:58 PM, Wacek Kusnierczyk
wrote:
> wow! :)
>
> vQ
>
> Henrik Bengtsson wrote:
>> library(gsubfn)
>> library(gtools)
>> library(rbenchmark)
>>
>>
wow! :)
vQ
Henrik Bengtsson wrote:
> library(gsubfn)
> library(gtools)
> library(rbenchmark)
>
> n <- 1
> df <- data.frame(
> a = rnorm(n),
> b = rnorm(n),
> c = rnorm(n),
> ip = replicate(n, paste(sample(255, 4), collapse='.'), simplify=TRUE)
> )
>
> res <- benchmark(columns=c('test'
library(gsubfn)
library(gtools)
library(rbenchmark)
n <- 1
df <- data.frame(
a = rnorm(n),
b = rnorm(n),
c = rnorm(n),
ip = replicate(n, paste(sample(255, 4), collapse='.'), simplify=TRUE)
)
res <- benchmark(columns=c('test', 'elapsed'), replications=10, order=NULL,
peda = {
con
edwin Sendjaja wrote:
> Hi VQ,
>
> Thank you. It works like charm. But I think Peter's code is faster. What is
> the difference?
>
i think peter's code is more r-elegant, though less generic. here's a
quick test, with not so surprising results. gsubfn is implemented in r,
not c, and it is p
Here is yet another way:
library(gtools)
DF[mixedorder(DF$ip), ]
On Fri, May 29, 2009 at 12:51 AM, edwin Sendjaja wrote:
>
> Hi,
>
> Is there any way to sort a tabel with a colum with IP-address?
>
> table:
>
> id rank color status ip
> 138 29746 yellow no 162.131.58.26
> 138 29746 red yes 16
PM, edwin Sendjaja wrote:
>
> Hi VQ,
>
> Thank you. It works like charm. But I think Peter's code is faster. What is
> the difference?
>
>
> Eddie
>
>
>
>
> > Date: Fri, 29 May 2009 11:44:15 +0200
> > From: waclaw.marcin.kusnierc...@idi.ntnu.no
Hi VQ,
Thank you. It works like charm. But I think Peter's code is faster. What is the
difference?
Eddie
> Date: Fri, 29 May 2009 11:44:15 +0200
> From: waclaw.marcin.kusnierc...@idi.ntnu.no
> To: p.dalga...@biostat.ku.dk
> CC: r-help@r-project.org
> Subject
Hi Peter,
This works as I expected. Thank you very much.
Eddie
> Date: Fri, 29 May 2009 11:15:37 +0200
> From: p.dalga...@biostat.ku.dk
> To: all...@cybaea.com
> CC: r-help@r-project.org
> Subject: Re: [R] IP-Address
>
> Allan Engelhardt wrote:
> >
9:59:40 +0100
> From: all...@cybaea.com
> To: edwin_0...@msn.com
> CC: r-help@r-project.org
> Subject: Re: [R] IP-Address
>
> IP addresses are very (very!) difficult to parse and sort correctly
> because there are all sorts of supported formats. Try to use something
> l
Peter Dalgaard wrote:
> Allan Engelhardt wrote:
>
>> [...]
>> Getting rid of the conversions including the matrix(unlist) combo is
>> left as an exercise (it's too hot here)
>>
>
> Here's one way:
>
> con <- textConnection(as.character(a$ip))
> o <- do.call(order,read.table(con,sep=".")
Peter Dalgaard wrote:
> Allan Engelhardt wrote:
>
>> IP addresses are very (very!) difficult to parse and sort correctly
>> because there are all sorts of supported formats. Try to use something
>> like PostgreSQL instead: it is already implemented there. But if you
>> are sure all your data i
normalizedip <- function(ipstring){
ipsepstring <- strsplit(ipstring,"\\.")[[1]]
cat(sapply(ipsepstring,function(x)
sprintf("%03i",as.numeric(x))),sep=".")
}
normalizedip("1.2.3.55")
yields
"001.002.003.055"
and therefore should allow you to sort in correct order.
edwin Sendjaja wrot
Allan Engelhardt wrote:
> IP addresses are very (very!) difficult to parse and sort correctly
> because there are all sorts of supported formats. Try to use something
> like PostgreSQL instead: it is already implemented there. But if you
> are sure all your data is of the n.n.n.n form, then somet
IP addresses are very (very!) difficult to parse and sort correctly
because there are all sorts of supported formats. Try to use something
like PostgreSQL instead: it is already implemented there. But if you
are sure all your data is of the n.n.n.n form, then something along the
lines of the
Hi,
Is there any way to sort a tabel with a colum with IP-address?
table:
id rank color status ip
138 29746 yellow no 162.131.58.26
138 29746 red yes 162.131.58.16
138 29746 blue yes 162.131.58.10
138 29746 red no 162.131.58.17
138 29746 yellow no 162.131.58.14
138 29746 red no 162.131.58.
30 matches
Mail list logo