Hot answers tagged

3

There are two important things in random forests: "bagging" and "random". Broadly speaking: bagging means that only a part of the "rows" are used at a time (see details here) while "random" means that only a small fraction of the "columns" (features, usually $\sqrt{m}$ as default) are used to make a single ...


2

You can simply use the color keyword in the aes function to refer to the variable based on which you want to color your points (see also this answer on stackoverflow): ggplot(data, aes(x, y)) + geom_count(aes(color=..n..), alpha=0.5)


2

You should be able to simply specify the field to be used for the linetype for the linetype argument within an aes mapping as follows: posneg_plot2 <- d_posneg %>% ggplot(mapping = aes(x=year, y=rel_freq, group=emotion_dict, colour=emotion_dict)) + geom_line(aes(linetype=emotion_dict), alpha = 1, size=0.7, colour="black")


2

I suggest to use R since it is open source and very powerful and thus is used by many companies and researchers. R does not only allow to deal with large amounts of data, it also allows to do state-of-art statistical analysis, including Tensorflow/Keras etc.


1

The way I read it, you want to transform home to contain numbers instead of text, with similar numbers representing similar homeworlds. As r correctly states, you cannot turn a list into a single numeric (double) value. Instead, you first have to convert the list into a factor. To do this in R, you run: data(starwars, package = "dplyr") df <- ...


1

Most likely the features are not sufficiently discriminative for class 2: class 2 data points are mixed with some of the other classes, and the model cannot distinguish them so it predicts the most likely class. To investigate more precisely the first step is to look at the confusion matrix: see which other classes the class 2 instances are confused with. ...


1

Would the following work for you? The following code should count the number of unique values in the lemma column within each group based on the year column. library(dplyr) library(tidyr) df %>% group_by(year) %>% summarise(count = n_distinct(lemma))


1

In the comments you wrote: I can't exclude it because it is related on an other feature If you mean related as in a function of two other features, you could add columns to explicitly show those relations, then delete the original column. E.g. add a column called petal.width.plus.length and then remove petal.width. Taking a step back, I think your problem ...


Only top voted, non community-wiki answers of a minimum length are eligible