HNHacker News
TopNewBestAskShowJobs

ggrothendieck

94 karma · joined October 10, 2013

submissionscomments
ggrothendieck··on Why are UK electricity bills so expensive?
Gas production from the North Sea is low because they imposed onerous windfall surtaxes on it so now it is unattractive to produce.
ggrothendieck··on Solving 100 Bushels Using Matrix Factorization
In R `nnls` (nonnegative least squares) does not guarantee integrality but in this case does give one solution and it happens to be integral: `library(nnls); nnls(A, b)`
ggrothendieck··on React for R
The poorman package (on CRAN) implements a lot of tidyverse with no dependencies. Other packages that provide alternate implementations are datawizard and tidytable.
ggrothendieck··on Rejected from YC. Reason: Because I don't have a cofounder
We used to call stuff like this "the warm body clause".
ggrothendieck··on Double-entry bookkeeping as a directed graph
David P. Ellerman has a mathematical approach to accounting based on what he refers to as the Pacioli group. A provisional element of the Pacioli group looks like x//y where x and y are non-negative integers and we form equivalence classes based on x//y and u//v being equivalent if the cross sums x+v and y+u are equal. The group operation is x//y + u//v = (x+u)//(y+v) and the inverse of x//y is y//x . The identity element is 0//0. For more info see, for example, https://ellerman.org/wp-content/uploads/2012/12/DEB-Math-Mag...
ggrothendieck··on Maersk to cut 10k jobs as shipping demand drops
The HN news title seems inaccurate. This is not necessarily a drop in demand nor is it applicable to all shipping as also suggested by the title.

The article suggests it is an oversupply of container ships with very few ships scrapped as opposed to demand: "The industry invested heavily in new container ships during and after the pandemic to meet strong demand and benefit from record freight rates. A large number of new ships entered the market since the summer with no signs of idling or scrapping, said Clerc."

Furthermore just because container ships were over ordered does not mean that other types of ships were so it is misleading to just refer to shipping in the title. It should be "container shipping".

ggrothendieck··on Ask HN: Books that teach programming by building a series of small projects?
Per Brinch Handsen, Programming a Personal Computer. Book is online. Interpreter, editor and OS in about 10 KLOC. http://pascal.hansotten.com/per-brinch-hansen/ Also https://news.ycombinator.com/item?id=24913959
ggrothendieck··on One Year with R
Of course it is possible to screw up but if you don't update your packages and record the date that does not seem to be R's fault.
ggrothendieck··on One Year with R
The packages that were used in statistics were SAS, SPSS and Stata. perl is not a statistical package and has nowhere near the depth of statistical capabilities of R.

Don't forget that I also mentioned the checkpoint package in my post. You only need to know the date for that, not the version of each of the packages.

In your last paragraph I think you are referring more to software development practices than what is available through R. Simply using R or any language doesn't guarantee this.

ggrothendieck··on One Year with R
Is the subset R interpreter you wrote available on the net?
ggrothendieck··on One Year with R
1. Before R commercial statistical packages were mainly used. You can, in principle, just use assembler too and develop everything yourself but it isn't practical. Regarding C/C++ and Fortran, many R packages are, in fact, wrappers around code in those or other languages making it easier to access them. From that point of view R can be regarded as a glue language. 2. Regarding keeping versions straight, all past versions of packages in the CRAN repository are kept on CRAN. Microsoft MRAN repository also maintains histories of packages that can be accessed via the checkpoint package which will install packages as they existed on a given date. Furthermore, install_version in the remotes and devtools packages can install specific versions. 3. Regarding tidyverse dependencies you can reduce the number of packages you load by not using library(tidyverse) and instead load the specific packages you need. This will result in fewer packages being loaded.
ggrothendieck··on One Year with R
What needs to be added is that before R the reproducibility problem in science was compounded by the fact that analyses were done with proprietary software limiting communication and replication of those analyses. This was and continues to be a major problem, particular in some fields, but at least now there is a common widely used language that can be used to overcome this. I wouldn't focus on idiosyncrasies but rather on the major problem it addresses. Any large system will grow over time and have some inconsistencies but after a while you learn the workarounds so they are less important than the big picture.
ggrothendieck··on Study findings do not support the use of ivermectin for patients with Covid-19
Furthermore a test just twice as large would be sufficient to determine significance at the 1% level even with a two sided test if the same death rate continued to hold.

  ivm <- c(3, 247-3)
  con <- c(10, 249-10)
  m <- rbind(ivm, con)
  fisher.test(2*m)$p.value  # 2* so that it is twice as large
  ## [1] 0.008490957
ggrothendieck··on Study findings do not support the use of ivermectin for patients with Covid-19
The Mech Vent and ICU also used two sided tests.
ggrothendieck··on Study findings do not support the use of ivermectin for patients with Covid-19
Also they say they used the Fisher exact test and got a p value for mortality of 0.09 so it seems they were doing a two-sided test which is the default for fisher.test in R.

  ivm <- c(3, 247-3)
  con <- c(10, 249-10)
  m <- rbind(ivm, con)

  fisher.test(m)$p.value
  ## [1] 0.08809225
However, I think a one sided test could be justified and in that case it is significant at the 5% level.

  fisher.test(m, alternative = "less")$p.value
  ##        ivm 
  ## 0.04541928
ggrothendieck··on Study findings do not support the use of ivermectin for patients with Covid-19
Not being statistically significant is not a proof that it doesn't work -- it only means they could not reject the possibility that the results were due to chance. The possibility that it slashed the death rate by 3x (which is what happened in the study) when projected to the world wide deaths of ~ 4.5 million would imply saving the lives of 3 million people so it certainly would be worthwhile to check it out. Maybe it was due to chance but maybe it was not.
ggrothendieck··on Study findings do not support the use of ivermectin for patients with Covid-19
If we look at the secondary endpoints note that 3x as many died in the control group, 2.5x as many needed mechanical ventilation and one third more need to go to the ICU.

            Ivermectin   Control
  n         247          249
  Mech vent   4           10
  ICU         6            8
  Died        3           10
These may not have been primary endpoints and may not have been statistically significant but it does raise the question of whether they would have been significant had a larger sample size been used.
ggrothendieck··on PRQL – A proposal for a better SQL
The link refers to dplyr not being able to use databases but actually there is a database backend for it in package dbplyr. See https://dbplyr.tidyverse.org/
ggrothendieck··on Teaching a cheap ethernet switch new tricks (2019)
> plug a USB device in that has all my media files on it

If you have multiple radios (like I do) that would require physically moving the USB from one to another.

ggrothendieck··on Teaching a cheap ethernet switch new tricks (2019)
At the time that CCrane, Grace and others started offering internet radios everyone was using Reciva and articles at the time referred to it as the Microsoft of internet radio so I don't think anyone at the time could have expected its downfall. This was really regarded as the safe bet. Also Grace has not offered a Reciva based radio for quite a few years so you must have quite an old one and have gotten many years of use out of it.

The CC Wifi 3 I got to replace my CC Wifi does have some anti-obsolescence features. It can be used as a bluetooth speaker and it has a built in web server that you can connect into from a browser and manually enter the URLs of streams so even if the Skytunes backend goes defunct like Reciva did the radio should still be somewhat usable.

If your radio can receive bluetooth you could put your media on a uPnP server, access it using vlc on a smartphone and then from there send it via bluetooth to the radio using it as a bluetooth speaker. That is probably more convenient than mucking with the radio to select audio files since you can do it on your smartphone with a better user interface. Anyways, that is what I do.

ggrothendieck··on Teaching a cheap ethernet switch new tricks (2019)
> Grace Digital bricked my three GD streaming devices

If you are referring to a Reciva based internet radio the web site which powers them was shut down by the owner of that site, not by Grace Digital. Also, if it is similar to my CC Wifi Reciva based radio it is still possible to access existing presets on the radio although you can no longer add presets or modify them any more. When you power it on wait for the Network Error caused by the lack of the back end and then press Back twice and then a preset. The media server functionality also still works.

ggrothendieck··on CSV Reader Benchmarks: Julia Reads CSVs 10-20x Faster than Python and R
The vroom R package is likely the fastest R package in read speed, not the ones used in this article. vroom was 13.1x faster than R's fread/data.table based on the read performance benchmark in https://cran.r-project.org/web/packages/vroom/vignettes/benc... so may be similar or faster in read speed vs julia.
ggrothendieck··on $1 hearing aid could treat millions with hearing loss
Personal sound amplification devices already exist at significantly less cost than conventional hearing aids. https://jamanetwork.com/journals/jama/fullarticle/2635618 https://www.nytimes.com/wirecutter/reviews/best-personal-sou...
ggrothendieck··on Researchers create air filter that can kill the coronavirus
This may destroy viruses but it does not kill them as viruses are not alive.
ggrothendieck··on R 4.0
Correct. One can write r"(c:\Windows\System32)" . Check out additional examples at the end of the help file: https://github.com/wch/r-source/blob/trunk/src/library/base/...
ggrothendieck··on R 4.0
The new C++ derived syntax for string literals seems to me to be the top new feature. It will make it possible to support markdown, latex, R code and Windows path literals without munging them first.
ggrothendieck··on The Phix Programming Language
This is related to the Euphoria language which has a long history so I gather this is not something that was quickly slapped together. http://phix.x10.mx/docs/html/eucompat.htm
ggrothendieck··on The strange magic of Swindon’s seven-in-one roundabout
The video claims roundabouts reduce accidents but according to the experience here: http://www.regionofwaterloo.ca/en/gettingAround/Roundabout-S... collisions involving injury or fatalities did decrease by 51% at intersections that were replaced by roundabouts; however, overall collisions at those intersections increased by 35%.
ggrothendieck··on How Elephants Avoid Cancer (2015)
You don't necesssarily need to know the rates. "If blue whales got 1,000 times more cancer than humans, they would likely die before they were able to reproduce and the species would quickly go extinct" yet the species does exist. http://www.ncbi.nlm.nih.gov/pmc/articles/PMC3060950/
ggrothendieck··on Fractal planting patterns yield optimal harvests, without central control
There is an agent-based model of Balinese irrigation written in NetLogo here: https://www.openabm.org/model/2221/version/3/view
Page 1 of 2Next →