News for hackers. Stuff that matters.
Re:Creating maps using R, Deedle and F# type providers by rjzzleep on Wednesday April 16, 2014 @10:50AM (#7598114)
mainly talking about f# here...

this looks like the classic example for f# type providers. there are a few talks tomas petricek[1] has given on that topic. the relevant talk is one of the skillsmatter talks[2]

i'm not sure if they're all publically available, but they used to be at least.

edit: but basically the summary is that you can do really cool things with type providers and have your ide(visual studio) give you full completion on parts of data you want to analyze. kinda like re# but without having to generate half a million lines of xml for web services.

there's also book coming up with chapters about it from tomas [3]

[1] http://tomasp.net/

[2] https://skillsmatter.com/members/tomasp#skillscasts

[3] http://www.manning.com/petricek2/

Re:Creating maps using R, Deedle and F# type providers by tpetricek on Wednesday April 16, 2014 @12:58PM (#7598943)
Thanks for pointing to my talks :-) I think the best recording available is on Channel 9 [1]. Though I really like this Mathias's demo, because it puts all the awesomeness in just 2 minutes, while I needed a full hour!

[1] http://channel9.msdn.com/posts/Understanding-the-World-with-...

Re:Creating maps using R, Deedle and F# type providers by platz on Wednesday April 16, 2014 @12:30PM (#7598745)
I've heard a lot about the amazing-ness of type providers, but no-one seems to know how they work aside from saying something betwen they generate types for you, and they generate intellisense for you.

I'm sure it all makes sense once you go ahead and play with it, but it looks like I'll have to be watching some videos to grok what is really going on.

Re:Creating maps using R, Deedle and F# type providers by kvb on Wednesday April 16, 2014 @01:09PM (#7599037)
Are you curious about using them or implementing them? What level of detail are you looking for?
Re:Creating maps using R, Deedle and F# type providers by platz on Wednesday April 16, 2014 @05:13PM (#7600561)
I think its knowing what's reasonable to expect from them and what's not reasonable i.e. what is static, what is dynamic, if there are artifacts how do they get created, what if the data schema is dirty...

some of these questions I can answer myself just playing around with them, but I think I'd have to be comfortable implementing them before being comfortable using them.

Re:Creating maps using R, Deedle and F# type providers by mmavnn on Wednesday April 16, 2014 @05:37PM (#7600704)
Slightly blowing my own trumpet, but if you want a brief overview of the basics this might help: http://blog.mavnn.co.uk/type-providers-from-the-ground-up/
Re:Creating maps using R, Deedle and F# type providers by platz on Wednesday April 16, 2014 @06:58PM (#7601045)
Thanks! I'll give it a read.
Re:Creating maps using R, Deedle and F# type providers by minimaxir on Wednesday April 16, 2014 @09:46AM (#7597686)
A great and easier package to work with for creating maps using pure R is ggmaps: http://journal.r-project.org/archive/2013-1/kahle-wickham.pd...

Here's an example map of San Francisco I made using ggmaps: http://i.imgur.com/zdetaKw.png

(The map was made for http://minimaxir.com/2014/04/san-francisco/ if you want more context.)

Re:Creating maps using R, Deedle and F# type providers by kvb on Wednesday April 16, 2014 @09:49AM (#7597707)
What makes it easier?
Re:Creating maps using R, Deedle and F# type providers by minimaxir on Wednesday April 16, 2014 @09:59AM (#7597769)
Looking at the code used in the OP, ggmaps does not require a dependy on a different program (and it also used a .dll, which may make it difficult to use cross-platform as well.). ggmaps also used ggplot2 syntax, making it easy for style customization which I don't see in the original code.

Although, using a shapefile adds another R package dependency, but not much more LOC. Alternatively, use the maps package, which also contains data for reconstructing popular maps like the world map used.

Re:Creating maps using R, Deedle and F# type providers by tonyabell on Wednesday April 16, 2014 @12:55PM (#7598909)
F# and its Type Providers have a strong cross platform story. http://fsharp.org/use/linux/ All the dlls referenced in the OP work on non windows platforms.
Re:Creating maps using R, Deedle and F# type providers by sremani on Wednesday April 16, 2014 @10:29AM (#7597972)
I am a novice in F# and pretty much have no idea about R, but what I can see here is that World Bank Type provider is providing the OP with the data.
Re:Creating maps using R, Deedle and F# type providers by minimaxir on Wednesday April 16, 2014 @11:18AM (#7598298)
Correct in this case, but you could use a simple CSV to get World Bank data as well.
Re:Creating maps using R, Deedle and F# type providers by tonyabell on Wednesday April 16, 2014 @12:50PM (#7598868)
The benefit of using a Type Provider over an CSV is it provides a strongly typed api to the data. Which gives you tooling (IntelliSense) and makes it hard to impossible to have type errors.
Re:Creating maps using R, Deedle and F# type providers by nightski on Wednesday April 16, 2014 @04:02PM (#7600224)
Type providers are available for CSV files also...
Re:Creating maps using R, Deedle and F# type providers by dalek2point3 on Wednesday April 16, 2014 @11:37AM (#7598416)
and remember if you need a basemap that is more than simply all the countries in the world, you can use openstreetmap.org! Downloads of raw data in various forms can be found at : download.geofabrik.de/