Skip to main content
Share Your Experience: Take the 2024 Developer Survey

Questions tagged [decision-trees]

A decision tree is a decision support tool that uses a tree-like graph or model of decisions and their possible consequences, including chance event outcomes, resource costs, and utility. It is one way to display an algorithm.

Filter by
Sorted by
Tagged with
0 votes
1 answer
160 views

Does it make sense to add a new calculated column for dates/duration?

I'm using a Random Forest Classifier on some data, and I have two date field, StartDate and EndDate. Does it make sense to ...
lte__'s user avatar
  • 1,320
0 votes
0 answers
97 views

Simple way to parse the rules of a Tree model

Problem Description I am currently working with simple decision tree models to generate rules to classify respondents of a survey. The output of each model is "translated" to the complete ...
Fnguyen's user avatar
  • 1,743
0 votes
1 answer
56 views

Give more weight to features based on distribution plot

I have a task to predict a binary variable purchase, their dataset is strongly imbalanced (10:100) and the models I have tried so far (mostly ensemble) fail. In ...
robsanna's user avatar
  • 101
0 votes
1 answer
272 views

Simple CART model example

My goal is to test Decision tree to regression model. My data is like below(python dataframe). There are 2 features F1 and F2. And there is label which is number. How to make CART model from this ...
Soon's user avatar
  • 115
0 votes
0 answers
117 views

Getting entropy in decision trees more than 1

My decision tree entropy is coming more than 1 when I'm calculating it manually. Not sure if there's some calculation error. Trying it on the Iris dataset. If I split on sepal length at 6.5 cm, my ...
Vishal Balaji's user avatar
0 votes
1 answer
106 views

Why -2 is seen in supervised binning using decision tree?

I have a continuous variable called salary, age etc and output variable as loan_status Instead of me choosing the cut off points for salary and age bins , I used Decision Tree to compute the bins ...
The Great's user avatar
  • 2,565
4 votes
1 answer
994 views

Are linear models better when dealing with too many features? If so, why?

I had to build a classification model in order to predict which what would be the user rating by using his/her review. (I was dealing with this dataset: Trip Advisor Hotel Reviews) After some ...
dsbr__0's user avatar
  • 191
1 vote
1 answer
230 views

Understanding feature_parallel distributed learning algorithm in LightGBMClassifier

I want to understand feature_parallel algorithm in LightGBMClassifier. It describes how it is done traditionally and how LightGBM...
figs_and_nuts's user avatar
1 vote
1 answer
409 views

SKLearn decisionTreeClassifier does not handle sparse or categorical data

Is there a way in fitting a decisionTreeClassifier in SKLearn to sparse tuples? The data that I have is based on about 100 features, but only a few of them are ever used to make the decision. ...
Bruce's user avatar
  • 196
0 votes
1 answer
912 views

Interpreting 'values' of a Decision Tree

I am trying to interpret my decision tree here which was resulted as a part of pre-pruning- I am trying to understand why the values in my nodes are in decimal places. Ideally, they should represent ...
ricardo's user avatar
  • 23
0 votes
0 answers
105 views

Where can I find the original CART(classification and regression trees) published paper?

I was trying to find the original CART paper. I found papers like https://www.researchgate.net/publication/227658748_Classification_and_Regression_Trees which experimented on CART but was unable to ...
Malyada N's user avatar
0 votes
0 answers
32 views

R: Handling tags in R rpart

I'm new to regression trees and wanted some advice. I'm working on a data set in which a few of the columns contains tag-like information (basically tags separated by commas). My goal is to create a ...
afwksh's user avatar
  • 1
3 votes
2 answers
101 views

How to control a decision tree?

This is my R script for a decision tree: ...
Inuraghe's user avatar
  • 481
0 votes
1 answer
36 views

How to drawing a decision tree?

This is my script for a decision tree in R: ...
Inuraghe's user avatar
  • 481
0 votes
1 answer
670 views

Tree based Classifiers with Label Encoder and One Hot Encoder [duplicate]

I m working with Tree-based classifiers in scikit-learn - Decision Trees and Random Forest, for a data classification use case, and the feature set is a mix of both categorical (majority) and ...
ranger101's user avatar
  • 101
0 votes
1 answer
89 views

Error with decision tree prediction

I write this script in R about decision tree. ...
Inuraghe's user avatar
  • 481
1 vote
1 answer
109 views

Reasons for a model predicting probability of being class 1 at x value

All, This is a general question. I have a binary classification which predicts if someone is rich or not. I had a question from someone asking that if the probability someone is rich is 0.6 and ...
Maths12's user avatar
  • 526
0 votes
0 answers
22 views

Handling repeating data from different individuals

I have a dataset that has some unique values but also includes information from multiple individuals that are repeating, meaning they are describing the same attributes and can have the same or ...
Patrick_Weber's user avatar
-1 votes
2 answers
180 views

How to implement ID3

I'm trying to follow the suggested outline form implementing ID3 ...
Evan Gertis's user avatar
0 votes
3 answers
148 views

Creating numeric word representation of input sentences resulting in MemoryError

I am trying to use CountVectorizer to obtain word numerical word representation of data which is essentialy list of 160000 English sentences: ...
Mahesha999's user avatar
1 vote
0 answers
759 views

Theoretical maximum depth of a decision tree

During my machine learning labwork, I was trying to fit a decision tree to the IRIS dataset (150 samples, 4 features). The maximum theoretical depth my tree can reach which is, for my understanding, ...
Souhaielrmx's user avatar
0 votes
1 answer
447 views

Catboost not able to handle a very simple dataset?

This is a post from a newbie and so might be a really poor question based on lack of knowledge. Thank you kindly! I'm using Catboost, which seems excellent, to fit a trivial dataset. The results are ...
user5406764's user avatar
1 vote
1 answer
370 views

Building a linear regression model for every combination vs only one Machine Learning model

So my question is more on the conceptual side. Given a dataset, I want to predict a given continuous variable Y. Now, there are 3 features, 2 categorical and one numerical (integer only). I know that ...
DPM's user avatar
  • 113
0 votes
0 answers
21 views

How to determine which classes are easier to predict with a decision tree?

So, I'm trying to work with decision trees on Iris dataset. I've noticed by trying out different parameter (max_depth, leaves etc) that some of the classes are easier to predict (most of the trees ...
Anđela Todorović's user avatar
1 vote
1 answer
28 views

Encoding distance variable that is continuous until out-of-range

I have a varaible distance which is continous until a "hard stop" at which we stop measuring the distance itself and just label the distance as "out ...
user1636588's user avatar
2 votes
4 answers
137 views

Predicting Disease Drugs

I have a dataset in the format: ...
Atom Store's user avatar
0 votes
1 answer
116 views

Feature importance by random forest and boosting tree when two features are heavy correlated [closed]

I have asked this question here but seems no one is interested in it. Here is my understanding, pls correct me if there is any misunderstanding: Tree models is used ...
user6703592's user avatar
1 vote
1 answer
29 views

If a feature has already split, will it hardly be selected to split again in the subsequent tree in a Gradient Boosting Tree

I have asked this question here, but seems no one was interested in it: https://stats.stackexchange.com/questions/550994/if-a-feature-has-already-split-will-it-hardly-be-selected-to-split-again-in-the ...
user6703592's user avatar
1 vote
0 answers
27 views

Difference between rpart models, one with information split the other with rpart.control

What is the difference between these two models? ...
cocoakrispies98's user avatar
2 votes
1 answer
38 views

classification balanced target y [0,1] but imbalanced feature x [many 0 , few 1s] , maximize precision

I have a simple dataset with balanced target y (0 or 1) ,and imbalanced feature (many 0 , few 1's) I aim to get high precision (don't care about recall) I can get high precision of 0.53 if I just ...
alexprice's user avatar
  • 221
1 vote
1 answer
855 views

Decision tree Why is Gini index only used for binary choices?

I would like to understand why "Gini index operates on the categorical target variables in terms of “success” or “failure” and performs only binary split" ? Why it would not be possible to ...
Edouard99's user avatar
0 votes
1 answer
50 views

What does "S" in Shannon's entropy stands for?

I see many machine learning texts using the following notation to represent Shannon's entropy in classification/supervised learning contexts: $$ H(S) = \sum_{i \in Y}p_i \log(p_i) $$ Where $p_i$ is ...
heresthebuzz's user avatar
0 votes
0 answers
49 views

Is there a "tree-based-correlation" for tree-based algorithms?

Although correlated features are not a big issue when training tree-based models, they spoil model explainability. When several features correlate, sometimes they may be picked at random. Then their ...
mikalai's user avatar
  • 164
1 vote
1 answer
39 views

How different classifiers would perform on a particular data set

I am reading through and learning how different ML methods work on different types of data, but I have faced a data set that I am not sure how ML methods, such as decision tree, Naive Bayes, and KNN, ...
user9532692's user avatar
0 votes
2 answers
94 views

GridSeachCV not performing well on ML models

...
Parth Sharma's user avatar
1 vote
0 answers
18 views

What kind of model to use to find drivers when data is aggregated and not on user level?

I have a website and have info from Google Analytics. So I can see the following "features": page url country device category (phone, desktop, etc.) Number of sessions Number of users: ...
user126224's user avatar
1 vote
2 answers
35 views

Multiple models have extreme differences during evaluation

My dataset has about 100k entries, 6 features, and the label is simple binary classification (about 65% zeros, 35% ones). When I train my dataset on different models: random forest, decision tree, ...
Egor's user avatar
  • 13
3 votes
0 answers
178 views

Non-greedy decision tree / random forest implementation(s) in Python

The standard random forest is trained using a greedy approach for computational feasibility. However, there are a number of alternative methods such as "lookahead" or using bilevel ...
Peter's user avatar
  • 7,526
2 votes
1 answer
49 views

Classifying short strings of text with additional context

I have a list of short strings each identifying a city. Misspellings are very common. The example below shows some of these short strings, along with the correct city they're supposed to match. ...
Jivan's user avatar
  • 165
1 vote
1 answer
899 views

How do I know if this model is overfitting?

This is my example R script for a decision tree: ...
Inuraghe's user avatar
  • 481
6 votes
3 answers
884 views

Is it possible to build ensemble models without a decision tree?

Is it possible to build ensemble models without a decision tree? I know that the description of ensembles itself suggests otherwise. However, I am really new to machine learning and all the ensemble ...
Raveen Diaz's user avatar
0 votes
1 answer
189 views

Best Way to find the important features for the model [duplicate]

I have data with 245 Features and almost all of the features are categorical. I would like to know what will be the best approach to find the important features for training the model. I know I can ...
Chris_007's user avatar
  • 193
3 votes
1 answer
5k views

What is the meaning of the Gini Index?

I'm studying random forest models, but I don't understand what the Gini index is and what it's for. Does anyone have any material on this or can give me an explanation? Thanks!
Inuraghe's user avatar
  • 481
0 votes
1 answer
23 views

Additional business rules in ensemble methods (RF, Boosted Trees)

How is it possible (if at all) to implement additional business constraints to an ensemble machine learning model, such as random forests or boosted trees? These additional business rules can be ...
Jivan's user avatar
  • 165
1 vote
0 answers
41 views

How are regression trees fitted in gradient boosting for classification?

What I understood is that even gradient boosting for binary classification uses regression trees. The first value we calculate is constant = log(odds). For the rest of the trees, we try to fit ...
Nikhil Mishra's user avatar
1 vote
1 answer
150 views

Scikit-learn's implementation of AdaBoost

I am trying to implement the AdaBoost algorithm in pure Python (or using NumPy if necessary)....
Mehdi Abbassi's user avatar
0 votes
1 answer
118 views

Does hyperparameter tuning of Decision Tree then use it in Adaboost individually vs Simultaneously yield the same results?

So, my predicament here is as follows, I performed hyperparameter tuning on a standalone Decision Tree classifier, and I got the best results, now comes the turn of Standalone Adaboost, but here is ...
SpaceSloth's user avatar
2 votes
2 answers
216 views

confused on "real score" vs "decision value" in classification trees

I'm reading the guide to XGBoost and am confused about the distinction it draws between the scoring systems of decision trees and classification/regression trees. The paragraph I am hung up on is: A ...
Sinnombre's user avatar
  • 153
1 vote
0 answers
51 views

Classification for Ordinal labels - what tree-based methds can i use?

I have a label that has a natural ordering e.g. 0,1,2,3 where 0 is the worst activity measure and 3 is the best. For each label given by the model i need to also give the probability that it belongs ...
Maths12's user avatar
  • 526
3 votes
3 answers
754 views

Is it possible to 'group features' for a decision tree model?

At each node of a decision tree, we must choose a collection of features to split along. Suppose we know a priori that the features can be partitioned into subsets that are 'correlated', i.e. this ...
Ryan Keathley's user avatar

1 2
3
4 5
16