Live data from Hacker News

Tools to get started in machine learning

k2company.com

21–30 of 37 posts

Re: Tools to get started in machine learning

#21
post #5

While I think Python is great, I think the author discounts R too casually. I share his frustrations about R, but what's nice is R (well, S) was designed to be a statistical computing tool, and it does anything related to that quite well. Especially for data analysis, which is where I spend a lot of my time (perhaps most) in the whole model building process, R is amazing. Also, R is very usable out of the box for mat…

With rpy2 you can even embed R code in Python.

Re: Tools to get started in machine learning

#22
>I found the syntax baffling, the documentation copious, but written for mathematicians instead of hackers

I'm always surprised how much people hate the syntax of R. I primarily work in Python, but I use R once or twice a week... and the syntax seems very clean to me. Can someone give mee an example of what you dislike with R's syntax?

I'm even more surprised to hear complaints about the documentation in R. The help files in R are much more complete and well organized than docstrings in the python libraries we use. Even the web usually lacks anything as useful as what I get from the vignettes function in my R interpreter.

Re: Tools to get started in machine learning

#23
A nice list of tools. We tried to use Python 3.0, but had the same problems as the author...

And if you are lucky enough to have free-ish access to MATLAB, here's a free, BSD, open-source, github repo'd machine learning toolbox to help you get started:

http://www.newfolderconsulting.com/prt/

Full disclosure: I'm involved.

Re: Tools to get started in machine learning

#24
post #10
post #9

Earlier quoted context omitted.

What's your background? (i.e. what do you already know?)

Probably not much. I started working with bigger data some months ago and now I notice that I need some real techniques and not just my "ok try this and this". I'm coding in C (where I "create" the data (numerical integration of stochastic differential equations)) and Python (plotting). I need methods/algorithms/techniques to analyse the data "on the fly" because I can't save it all (it's too much data).

Just a small tip which may ease the search for methods. The general term for "on the fly" learning is online learning [1]. The rest depends on your problem but there are often online variants of offline methods, e.g. when you work with Gaussian process regressions

[1]: http://en.wikipedia.org/wiki/Online_machine_learning

Re: Tools to get started in machine learning

#25
post #22

>I found the syntax baffling, the documentation copious, but written for mathematicians instead of hackers I'm always surprised how much people hate the syntax of R. I primarily work in Python, but I use R once or twice a week... and the syntax seems very clean to me. Can someone give mee an example of what you dislike with R's syntax? I'm even more surprised to hear complaints about the documentation in R. The help…

(Author here) - I don't have any specific examples, but I was learning R and Python at the same time. I found Python to be very practical and easy to learn. When learning R, I kept getting tripped up. Maybe it isn't that R was harder, but that I had a head start on Python. And as for documentation, R was certainly very complete, but once again, I found it harder. I think because R is written by, and probably for, professional statisticians and mathematicians, it needs to have a different level of rigor than the Python documentation. Anyway, sorry for the lack of specificity.

Re: Tools to get started in machine learning

#26

If you are going to use python for ML. Use the python package from Entthought [ http://www.enthought.com/products/epd_free.php ] It has most of the libraries, out of the box.

(Author) - Nice tip. Thanks - I'll update my list. (Wish I had known at the start of my learning!)

Re: Tools to get started in machine learning

#27
post #22

>I found the syntax baffling, the documentation copious, but written for mathematicians instead of hackers I'm always surprised how much people hate the syntax of R. I primarily work in Python, but I use R once or twice a week... and the syntax seems very clean to me. Can someone give mee an example of what you dislike with R's syntax? I'm even more surprised to hear complaints about the documentation in R. The help…

Personally it's not so much syntax as the confusing data model that gets me in R. So many different but very similar data types - lists, data frames, matrices, tables, vectors - all very similar but slightly different syntax, very frequently converted silently from one to the other when you call functions but resulting in strange quirks that are extremely hard to debug at the other end. The combination of loose data typing and this plethora of similar data types makes it a nightmare to work with at times. On the other hand when you grok it and it works for you ... it's amazing.

Re: Tools to get started in machine learning

#29
post #27
post #22

>I found the syntax baffling, the documentation copious, but written for mathematicians instead of hackers I'm always surprised how much people hate the syntax of R. I primarily work in Python, but I use R once or twice a week... and the syntax seems very clean to me. Can someone give mee an example of what you dislike with R's syntax? I'm even more surprised to hear complaints about the documentation in R. The help…

Personally it's not so much syntax as the confusing data model that gets me in R. So many different but very similar data types - lists, data frames, matrices, tables, vectors - all very similar but slightly different syntax, very frequently converted silently from one to the other when you call functions but resulting in strange quirks that are extremely hard to debug at the other end. The combination of loose data…

The complaints about R still seem counterintuitive to me. Python has the same data types listed above, and many more.

A list in R is a list in Python. A data frame in R is a date frame in the pandas library. A matrix in R is a matrix in numpy. A vector in R is a 1-dimensional ndarray in numpy.

But Python adds dictionaries, tuples, iterators, sets, and a bunch of other data types that aren't used in R.

R's lists and vectors are relatively similar... but you could say the same thing about numpy's matrix and ndarray. You could probably say the same thing about python's sets, tuples and lists.

To be honest, I'd have said the strength of python is that it has many more data types than R... rather than fewer data types.

Re: Tools to get started in machine learning

#30

Does anyone have any experience with Octave and how it compares to the Python setup that OP suggests? What are the benefits/pitfalls?

I have used Octave but only for the Coursera ML Class, not actual production use. My understanding is that it is the open source version of Matlab capable of running many Matlab programs.

I learned Octave first, then R, then Python.

Octave to me feels like Python + NumPy. I'd say Octave has more in common with R than with Python.

Given the choice between Octave and R, I'd choose R for the more robust user community and incredibly diverse and thorough selections of libraries.

Post reply on HN