Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [random-forest]

Random forest is a machine-learning classifier based on choosing random subsets of variables for each tree and using the most frequent tree output as the overall classification.

0
votes
1answer
14 views

Reducing MAE or RMSE of linear regression

I'm trying to guess a home price, at final I intend to figure out a formula by using linear regression. As you can see over the url, I have 1480 data with 45 features in which ...
0
votes
0answers
10 views

Random Forest Classifier: Find the decision path for a single data point

I am working with RandomForestClassifier and I would like to be able to analyse the decision path which each decision tree takes for a single data point. What I understand is that the final prediction ...
0
votes
0answers
26 views

Why is the random forest confusion matrix for my test dataset 100% accuracy, when training data matrix isn't?

I am using the software Orange to undertake a random forest classification of geo-chemical data. I am trying to classify points as 0 or 1 based on whether it is a mineral occurrence or not. My ...
0
votes
0answers
14 views

Predict vs. Impute: Filling missing data using Random Forest

I am using R package randomForest to build a Random Forest model for classification. Ultimately, I need to choose one of five programs for a group of individuals ...
0
votes
0answers
23 views

Effect Size in comparison of overall accuracy from Random Forest

I would like to compare two overall accuracy statistics (of a Random Forest classifier). My Data: two samples with each containing 25 features and one categorical class variables (9 different ...
0
votes
1answer
23 views

Random Forest application with 40+ Predictor Variables

I am using R package randomForest to build a Random Forest model for classification. Ultimately, I need to choose one of five programs for a group of individuals ...
0
votes
1answer
22 views

For binary classification, which is best Random Forest or Neural networks?

I had to perform a binary classification, and from the beginning I started thinking about using the Random Forest classifier. But now I'm thinking, if using a neural network would've not been better. ...
0
votes
0answers
11 views

Changing the performance metric used to optimize with random-forest

I'm looking to change the performance metric used to optimize the training for my data set because it is highly unbalance. Because it's highly unbalanced, I don't feel like accuracy is the appropriate ...
0
votes
1answer
17 views

How to Interpret the ROC Curve?

i plotted the ROC curve for RandomForest Classifier and this is what i get : The shape looks weird to me , can somebody help me to make sense of it , and is this shape 'common' to not say normal? ...
2
votes
2answers
78 views

Interpretation of ROC AUC score

i tried to evaluate 6 models and after plotting , this what i get : So i'm wondering , if those results are "Right" ? Thank's in advance.
1
vote
2answers
29 views

Large negative R2 or accuracy scores for random forest with GridSearchCV but not train_test_split

I'm trying to use GridSearchCV from scikit-learn and look at the difference between train/test metrics. When I do a normal test/train split with RandomForestRegressor, the metrics are comparable. ...
0
votes
1answer
34 views

Why is Random Forest feature importance biased towards high cadinality features?

I understand how a random forest algorithm works but could someone tell me the rationale behind Random Forest feature selection being biased towards high cardinality features?
1
vote
0answers
24 views

Random forest multivariate forecast in Python

I am working with a multivariate time-series dataset and have put together a Random Forest code (see below) to forecast the variable TM at a future time (by training the model using data pertaining to ...
0
votes
0answers
32 views

additional of features decrease the accuracy of the model

I am using sklearn's random forests module to predict a binary target variable based on 166 features. When I increase the number of dimensions to 175 the accuracy of the model decreases (from accuracy ...
0
votes
0answers
7 views

Correct use of model interpretability

I am working on a spam classifier with ~26 features where most of these features are of categorical type and only few of them numerical. I have built 3 models with random forest, gradient boosting and ...
2
votes
2answers
179 views

Why is random forest an improvement of decision tree?

Let's assume that we have a binary classification problem, and we built a decision tree on our data set. Assuming that we have 5 features, then the decision tree, in the first step, will choose the ...
0
votes
1answer
36 views

How to get the data from gender dataset

May I know how to modify my Python programming thus it will be get the same result as refer to the image file? ...
4
votes
1answer
61 views

How does the meta Random Forest Classifier determine the final classification?

I am trying to understand exactly how the meta random forest classifier determines the final prediction, I understand that there is a voting system and an aggregation from the decision trees is used ...
3
votes
1answer
37 views

What happens to the left over unpicked data in Random Forest

I believe in Random forest we pick random samples of training data with replacement. My question is there still is a possibility that we might leave some data out. What happens to that. Does it not ...
1
vote
2answers
42 views

Selection of Features and Data in Random Forest

First, I am confused whether at each node in all the trees, do we randomly pick features from the lot to be pitted for best split or does each tree get a random subset of feature and then all the ...
0
votes
0answers
16 views

How to identify one-to-many relation and discard one during feature selection

My data has many features out of which two features have one-to-many relation something like state and country. Now I want to do feature selection to identify key independent features for given ...
0
votes
1answer
28 views

Random Forest Techniques/Models

Can anyone tell about different Techniques/algorithms of Random forest? I know, Random Forest is itself an algorithm/model, but I'm looking for another version of it as we have in decision trees. List ...
0
votes
0answers
8 views

Automated Spatial data mining tools in python

How can spatial data raster be processed in order to apply random forest prediction algorithm on it using python programming language?
0
votes
1answer
27 views

Printing Feature Contributions in a Random Forest algorithm from the Treeinterpreter library leading to errors

I am working on a dataset where I predict the risks of developing pancreatic cancer with respect to a number of variables. I have created a random forest, and want to find the feature contributions. I ...
2
votes
2answers
32 views

Random-Forest-based Similarity Matrix for clustering: how does it behave?

I am in the following context: Data: static, baseline health data at the patient level, 40 features, sparse (~ 25 binary features with many 0 or many 1 + other categorical features) Objective : to ...
1
vote
1answer
24 views

Isolation Forest Score Function Theory

I am currently reading this paper on isolation forests. In the section about the score function, they mention the following. For context, $h(x)$ is definded as the path length of a data point ...
1
vote
0answers
38 views

RandomForestRegressor intermittantly returning a single prediction

BACKGROUND I have a RandomForestRegressor from scikit-learn which, for each example row, takes in four float features and ...
0
votes
1answer
150 views

predict_proba returns different results on Python 2 & 3

I had some old code used to train a Random Forest Classifier (sklearn 0.17.1), for classification on two classes (spam/ham). I ran this in a docker container and sent it some data. Sklearns ...
1
vote
3answers
58 views

Why did Logistic regression perform better than svm? [closed]

I have a data set of movies and their subtitles.My task is to classify them based on their ratings-[R,NR,PG,PG-13,G]. I have tried different ML algorithms and found that Logistic regression out ...
5
votes
3answers
243 views

Regression vs Random Forest - Combination of features

I had a discussion with a friend and we were talking about the advantages of random forest over linear regression. At some point, my friend said that one of the advantages of the random forest over ...
4
votes
1answer
41 views

What does it mean to take the “average” of two decision trees by 'voting'

I have heard, in relation to random forest algorithm, that the algorithm will fit many decision trees and take the average of them by votes. (This is related to bagging as well) I understand what ...
0
votes
2answers
62 views

Random Forests Feature Selection on Time Series Data

I have a dataset with N amount of features, each one with 500 instances in time. Let's say that I have for example, the features x, y, v_x, v_y, a_x, a_y, j_x, j_y....
3
votes
2answers
70 views

why do we need row sampling in random forests?

In random forests, where our estimators are decision trees, we do column (feature) sampling without replacement within an estimator, and with replacement in between estimators. This is perfectly fine ...
1
vote
0answers
30 views

Kappa Goes up as Accuracy Goes Down

I have recently been trying to train a randomForest model on a binary outcome with a very uneven class split. 282 control ~82% 63 case ~18% There are a total of 147 predictors that I'm testing for ...
3
votes
2answers
64 views

What's the difference between feature importance from Random Forest and Pearson correlation coefficient

I have following business domain. I have a product with three outputs/labels. The outputs are impacted by 1000 procedures, each procedure is digitized and measured. The customer wants to know what is ...
0
votes
1answer
31 views

Evaluating the test set

Please find attached a part of the code which explains what I'm trying to do. Essentially I'm trying to predict the sales of supermarket stores. Im using RandomForestRegressor for this and have ...
2
votes
1answer
36 views

Dataset where svm performance is significantly different from random forest

Is there a specific dataset where svm performs significantly better or worse than random forest? I know that the performance could depend on the dataset but is there a specific dataset?
0
votes
0answers
27 views

Need help understanding time series approach used for predicting earthquake arrival?

In predicting the arrival time of earthquakes, a paper here seems to make use of a time series approach that is making me scratch my head, and I would appreciate any guidance on understanding it. In ...
0
votes
0answers
46 views

How can I recognise if I can improve a random forest model by adding features

I want to tune a random forest model with caret package. I'm tuning it with cross-validation to prevent overfitting and resulted cross-validation accuracy is very ...
1
vote
1answer
78 views

Get insights from Random forest::Variable Importance analysis

I run variable importance on my Panel data (TV viewing over specific period) which consists of the old-Panel (Panel 0) and the new panel (Panel 1) I am interested in understanding the differences in ...
0
votes
0answers
98 views

very low recall value using random forest

I have download this data-set which can be download from here. I have tried everything I can think of, such as one-hot encoding the output, standardisation, removing outliers, remove columns with too ...
2
votes
1answer
186 views

Why is performance worse when my time-series data is not shuffled prior to a train/test split vs. when it is shuffled prior to the split?

We are running RandomForest model on a time-series data. The model is run in real time and is refit every time a new row is added. Since it is a timeseries data, we set shuffle to false while ...
1
vote
0answers
27 views

Get Decision Tree Prediction With Random Forest

If I give random forest parameters as RandomForestClassifier(n_estimators=10,bootstrap=False,max_features=None,random_state=2019) Should it be creating 10 same ...
1
vote
0answers
37 views

How to encode H3 geohash in regression model

I'm trying to train a random forest regression model based on a number of features, including location. I know that raw lat/long can't be used directly, so I've bucketed them using H3. I'm struggling ...
3
votes
0answers
39 views

How to deal with count data in random forest

I am working on a classification model where my target class is a biased class with the class shape as 0 1 20694 101 Most of my features are the ...
1
vote
1answer
107 views

Is it possible to plot decision boundaries for only a subset of features?

I have a sklearn Random Forest classifier with 59 features as input. I'd like to plot the decision boundaries of only two features at indices i1 i2. If I use the average/median values for the ...
6
votes
1answer
84 views

Will unnecessary features harm the tree based model?

Is it necessary to drop noisy features (eg column of random numbers) from tree features? I think it's not. sometimes it may benefit but will never cause any harm to the model. Because at each split ...
0
votes
0answers
10 views

Is it possible to rank feature importance after training a recommender system?

I need to train a recommender system on some movie recommendation data. The thing is, I wanted to use a random forest for the model, since I know you can print a feature hierarchy, after training. I'...
0
votes
0answers
71 views

Relation between using stratify and class weights for imbalanced classes

I'm working on a multi-class classification problem where the classes are imbalanced (70:25:5). Train-Test Split ...
0
votes
0answers
46 views

What is the difference between PySpark's featuresCol, labelCol, predictionCol, and probabilityCol?

I am attempting to train a random forest classifier (pyspark.ml.classification.RandomForestClassifier) on a large dataset (~70gb). However, I am not sure what to ...