Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
hadley
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
21 ms
·
211.
▲
by
hadley
12y ago
Most of those problems have existing solutions. 1. Do you know about browser()? That gives you an interactive debugger on par with most programming languages. Also see the GUI wrapper to the debugger in RStudio. 2. Share a library (a collec
212.
▲
by
hadley
12y ago
It still does that. But it's an optimization for editing in place, not related to gc
213.
▲
by
hadley
12y ago
The whole R sucks as a language thing is getting pretty old. There is some things that R is really good at, there are some things that Python is really good at. Just because R comes from a somewhat unusual ancestry (firmly rooted in functio
214.
▲
by
hadley
12y ago
It's not really as bad as all that. The reason to avoid using those names is to avoid confusing the reader, not because it causes problems for R
215.
▲
by
hadley
12y ago
I gave up on Python long ago. Anything I want to do in Python, I can do just as easily in R. Rcpp provides a great environment for intermingling high performance c++ with expressive R code. R has all th r features you'd want for a mode
216.
▲
by
hadley
12y ago
Yes and yes. R is lexically scoped
217.
▲
by
hadley
12y ago
FWIW The performance difference is insignificant unless your working with >>10 of millions of rows.
218.
▲
by
hadley
12y ago
Thanks for the kind words :)
219.
▲
by
hadley
12y ago
Recent benchmarks show the performance of pandas, data.table and dplyr to be pretty similar, with data.table usually being the fastest.
220.
▲
by
hadley
12y ago
Yes, r functions are very similar to fexprs
221.
▲
Lowliner: FP infrastructure for R in the style of underscore.js
(github.com)
6 points
by
hadley
12y ago
|
0 comments
222.
▲
by
hadley
12y ago
What does adding two dates together mean?
223.
▲
by
hadley
12y ago
That's a great explanation! Data frame for data analysis; matrix for math.
224.
▲
by
hadley
12y ago
I've never found that to be a problem in practice. Do you have an example where it's bitten you in practice? (Also you should use UTC and not GMT)
225.
▲
by
hadley
12y ago
Unless you're doing linear algebra (or really care about memory usage), you almost never need to use a matrix in R.
226.
▲
by
hadley
12y ago
Have a look at http://adv-r.had.co.nz/Subsetting.html#subsetting-operators . There was just too much material to fit in one chapter.
227.
▲
by
hadley
12y ago
I'd start here: https://github.com/Rdatatable/data.table/wiki/Benchmarks-:-G... Performance isn't currently a huge focus for dplyr. In my opinion dplyr is fast enough that the bottleneck becomes mos
228.
▲
by
hadley
12y ago
Not that I'm aware of - rvest uses the R package XML which uses the C library libxml.
229.
▲
by
hadley
12y ago
FWIW we don't do any consulting, although we do a decent amount of training.
230.
▲
by
hadley
12y ago
What are you looking for? rvest should support all the navigation tools from beautiful soup/nokogiri (unless I've missed something), but currently doesn't have any support for modifying the document (in which case I think you
231.
▲
by
hadley
12y ago
Yes. It uses httr which wraps RCurl in such a way that everything should just work.
232.
▲
by
hadley
12y ago
If you're confused about R's data structures, please read http://adv-r.had.co.nz/Data-structures.html and let me know if it doesn't help. And no, we're not planning on burning out. We currently sell thre
233.
▲
by
hadley
12y ago
Can you provide a bit more detail?
234.
▲
Rvest: Easy web scraping with R
(blog.rstudio.org)
142 points
by
hadley
12y ago
|
28 comments
235.
▲
by
hadley
12y ago
http://adv-r.had.co.nz/dsl.html and the two prior chapters
236.
▲
by
hadley
12y ago
NB: sqldf works by copying your data frame into a temporary SQLite database, running the query and then copying the data back. So it's not that fast. Instead, learn a native R package like dplyr or data.table that supports all the powe
237.
▲
by
hadley
12y ago
The closest equivalent to virtualenv for R is packrat: http://rstudio.github.io/packrat/ . It doesn't (yet) support different R versions for different projects, but that's on the roadmap.
238.
▲
by
hadley
12y ago
Or try "Advanced R", http://adv-r.had.co.nz . It's my attempt to explain the language in such a way that programmers from other languages can appreciate the beauty and elegance behind the quirkiness.
239.
▲
by
hadley
12y ago
I think R is a well-designed language. It definitely has its quirks (what language doesn't?), but by-and-large they are problems with the standard library, not the language. This is admittedly a subtle distinction, but it's much e
240.
▲
by
hadley
12y ago
There are three areas where I think R is the clear winner: 1) An IDE for data analysis/programming: RStudio 2) Easy way to turn your analyses into reports: knitr 3) Easy way to turn your analyses into interactive webapps: shiny (I also
More ›