Statslet here

Statslet here.
Can someone please explain me the advantages of R over Python? I just cannot make sense of R's type system and syntax is ugly.
Does R provide better libs? What Actually do I miss if I use python only?

Other urls found in this thread:

github.com/stan-dev/rstan/wiki/RStan-Getting-Started
courses.edx.org/courses/course-v1:UCSanDiegoX DSE200x 2T2017/course/
twitter.com/SFWRedditGifs

R was designed thinking about stats and python is general purpose. python is way more clean but for specific things you'll have to write way less code in R. If you are into stats, learn both. you probably miss little if you use python only

Exactly this.

How good should I be in R to be a good statistitian/"""data scientist"""?

Better IDE, better convenience functions. It's a comfy language.

Also what are your major trip ups with R's data types?

How Rstudio is better that pycharm? It is a good ide, but I cant think about a single aspect where pycharm is worse.

I was considering base release: Rgui vs IDLE. Personally I hate Rstudio.

They are not intuitive like in other languages.
What is the difference between vector, array and list? I googled it, but it still isnt completely clear to me.

Whats wrong with external ides?

R and Python are both high-level languages; anything you do in one can be also be done in the other, though certain things like statistical tests will be easier to implement in R than Python.

If you have no prior experience with statistics but want to git gud, I'd strongly advise you to study the theory before learning R, or at least doing both concurrently. fortunes::fortune(184) is probably relevant here.

Good statisticians write good R code because they think like good statisticians and the language enables them to express their thoughts in an idiomatic fashion. R is fairly aggressive about this, so the converse also holds: people who are bad at statistical analysis (even if they may be good programmers) will find the language unintuitive as it forces them to write their programs in a manner that is uncomfortable for them.

A vector is what you'd call a list/tuple in python, just a single dimension series of values. All values in a vector have to have the same type (numeric or Boolean or string etc). An array is a vector extended to multiple dimensions, like a matrix. Same rules apply wrt types. A list is what you use when you have different data types and potentially different data sizes you want to store in a single object.

Say you want to store a bunch of observations, where you have 20 measurements from each experiment. A matrix (or a data frame) would be a good way to store that, you just set up the table and populate it.

Now say you had a different situation where you wanted to store someone's name and a variable set of information on them. For some people you might have one piece of info, for others you might have ten. No one array will suffice, but you can structure your data in a list. The list packages the data together.

Nothing is wrong with them, I just don't think they should be part of the discussion if you're comparing languages.

But isn there a special type for matrix?

A matrix is a 2d array. They're identical types under the hood. The matrix() function is just sugar.

Oh, thanks.
By the way, what is your degree? Also what do you mean by "good statisticians"?

ah that was someone else that posted , you'll have to ask them.

im a biologist

R is not even a real programming language, R sucks dude.

Neither is Python.
Python is a scripting language.

t. cs brainlet

could not be more wrong

How long to learn R from the ground up? Know my stats theory, just interested in how long it takes to learn all the language, ggplot2 and the like libraries.

There are hundreds of libs, I honestly have no Idea how one should deal with them.

Yeah, but seeing a 700 pages long book on ggplot2 alone kinda killed my motivation. Do you recommend any other library besides ggplot though?

> 700 pages long book on ggplot2

like with any language: start simple. you don't need ggplot2 to get started, base graphics are fine for learning.

R base is fine for most use. all the external packages tend to deal with hyperspecific use cases that 99.9% of people don't need to give a shit about.

R has a lot of data sets built into the default install, and if you want to learn to do exploratory data analysis, you only need base R.

ignore all the extra shit until you have a specific need for it

and to expand on that:

if you have any basic programming knowledge, R is easy to pick up. it's a high level language, honestly a lot like python except for syntax.

the most useful thing you can do is learn to deal with data frames and how to do complex subsetting. get used to using boolean descriptions in subsetting, and how to cross reference between data frames (subset a metadata data frame to get columns of interest, then query your data storage data frame with the information from the metadata frame). data frames are the bread and butter of R

also: i think the biggest hangup people might have with R is that most of it's basic data manipulation functions are return-edited-object, but there are a few (row/colnames() come to mind) that are edit in place. that and, if you try to do something like,

x

STATA

What do you think about Wolfram Mathematica, fellow statisticians?

have no experience, but to my knowledge it's kind of a different different beast

i think of it in terms of say, matlab verses mathematica/maple

you can twist one to approximate the other, but it's just really not hte same thing

Can you get PyCharm to show variable assignments in a live workspace like RStudio or Octave GUI? I always use IPython when I'm doing something quick in Python

Yes, to some extend.

It looks like a really powerful tool, but it is expensive, maybe thats why there isnt a lot of information about it.

Question doesn't really make much sense cos of , but stay the fuck away from both, use MatLab if you want to learn something by writing models yourself, and not just execute "open source" functions made by autists

C is a programming language, Python is just an attempt at ideologically-based sugar coding made by an autistic sperglord

found the mongoloid

Why cant one write his own functions in r or python? Also I expect most of libs to be written in c++, and one can easily integrate c++ to python, and probably to r also.
And matlab isnt free.
And why should one write his own functions, when he can simply read the theory of the used algorithm?

Asm is a programming language, C is just an attempt at ideologically-based sugar coding made by an autistic sperglord

>And why should one write his own functions, when he can simply read the theory of the used algorithm?
You haven't really understood a model until you can rebuild it from scratch. Bottom-up is for people who understand, Top-down is for management school retards who just click play. It becomes important when you start working on real data and your functions fit like shit, you need to understand precisely where the problem is

> ihih look mom I made an abstraction joke im so smart

Except there is no official C penis enlargement scam-looking web page filled with shit like "elegant is better than ugly"

>using anything else than MATLAB

How about SAS is it the safest pickup for the job market? Is it better?

You actually make me think about R being better than Python. Though you cant deny that python has a number of useful libs.

t. mathworks sales

No no no wait

I love to shit on Python because it deserves it, but I still consider it a legitimate programming language and it saved my ass when I needed to use Tensorflow, credit where credit is due.

R, on the other hand, is the most autistic project ever conceived, because it's a language mantained by statisticians and not by computer scientists, which makes it ugly, incredibly tedious to use, and completely unpredictable (like that time when they discontinued the tseries packet JUST BECAUSE). Stay the fuck away from R and consider yourself free to assume anyone who uses it is a complete autist

matlab sucks for statistics though

if you're doing statistics and you're not using R then you're fucking up bad

>not getting matlab automatically for no extra cost when you went to university

I finished university 2 years ago and I can still use matlab on my computer

no u

cython + stan

stan is also available for R, and besides, statistical work is a lot more than just Bayesian modeling.

Someone develop this please

what are the best books for learning how to use python for data/stats stuff? ive heard libraries like scipy being thrown around, i want to learn how to use those.

>Asm is a programming language
WRONG

develop what? rstan is already a thing: github.com/stan-dev/rstan/wiki/RStan-Getting-Started

"Statslet".... I am so done with this dumb website.

If you have a choice in the matter, R is a lot cleaner for stats. Having used both R and python's pandas and numpy libraries, things are a lot nicer in R. Not to say there's anything wrong with python, but it's obvious it wasn't built specifically for statistics like R is.

Also, R runs way faster for run-of-the-mill data manipulation in my experience.

Asm is a programming language. Even hex is a programming language.

>I'd strongly advise you to study the theory before learning R
I wanted to do exactly that, can you give couple of good textbooks? Being a russkie myself, I have little idea about your textbooks.

Пpивeт. Кaкoй y тeбя бэкгpayнд?

quantum physics

Dont you have to know probability to do quantum physics?

on the basic level. For statistical mechanics you need to know more, but none of that was 'data analysis' oriented. It was "statistics for physicists".

I am reading Bishop Patrern recognition and machine learning now.

What about you? Yandex schooler by any chance?

courses.edx.org/courses/course-v1:UCSanDiegoX DSE200x 2T2017/course/
maybe you can start with this and see how it goes. For me it was ok, but a little boring

t. statslet

No, Yandex is to hard to get for me. Just a brainlet undergrad in the uk.

I personally find manipulating data easier with R than Python. Also there seems to be far less work involved to achieve a result with.

RStudio is the best ide. Prove me wrong.

Relative to Rgui, noticeable response lag even for incredibly simple operations like addition, and very slow startup times.

You should check out the swirl package in R. That's what I'm using to learn R, and it goes through some stat concepts as well.

To learn the basics of stat, check out www.burkeyacademy.com. It's run by an economics professor, but it has a decent amount of stat courses, as well as a little bit of R. Also, if you're interested econometrics, there are a bunch of those courses as well.

Same here bruh.

so is my dick in ur mom s ass

couldnt tell you much, but my tutor who's teaching our data analysis class uses python exclusively for his data work contracting and gave us the option to learn using that, when the university curiculum tells us to learn SAS. My team chose python. It's tough and less intuitive but its free and doesn't require the funds of a large company to have use.

the best post on Veeky Forums

God I hate R. it has the most autistic community of any language ever, and im including lispers and haskelians in that.

Even when I cant find a python library to do something (most recently to find linear combinations of time series that are stationary) i rather use r2py and run the R code in python than open up an R ide.

Python also has its share of shit, like non existent documentation for 90% of what you want to do, and hundreds of abandoned libraries that force you to use outdated versions of other libraries and get them to run, and bugs in major modules like pandas that have been reported since 2014 but are still not fixed.

Both are just shit languages actually. But python is by far the less shit one.

I've been waiting for this thread all my life

swirl is literally brainlet tier. Takes you through the basics but nothing else.

it's not even really good for teaching, just as a refresher if you've been away from the language for a while

Use a real language, OP

Is it french?

no

I joined a research project where I'll have to use R before even taking statistics. If what you're saying is true I'm screwed.

>MUH TYPES

You too. Keep your autism in .

R is designed as a vector-based language. It also works better as a functional language. It's easier to implement stats-based packages like data clustering or machine learning.

The problem is that it's slower for the sake of readability