Stack Exchange Network

Stack Exchange network consists of 174 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 [categorical-data]

Categorical (also called nominal) data can take on a limited number of possible values called categories. Categorical values "label", they do not "measure". Please use [ordinal-data] tag for discrete but ordered data types.

1
vote
1answer
25 views

(Low cardinality) categorical features handling in gradient boosting libraries

In some popular gradient boosting libraries (lgb, catboost), they all seems like can handle categorical inputs by just specifying the column names of the categorical features, and pass it into a ...
0
votes
0answers
13 views

Bootstrapped linear regression with unbalanced factors

I am investigating the relationship between Valence ratings (continuous response variable) and Condition (4-level factor) as ...
0
votes
1answer
16 views

Analysing partially ordered responses

I'd like to analyse judges' decisions on bail. Ie some decisions (remand in prison) and clearly worse than others (unconditional bail). But in the middle there are a range of possible responses that ...
4
votes
1answer
38 views

Is there a statistical test for comparing count/frequency of different groups (just one dimension)?

This seems very simple question, but I could not get my head through it. The data is like below: In the sample of 30 patients, patients can have four types of treatment. we want to know whether B ...
0
votes
1answer
21 views

How to interpret a boxplot to check for assumptions?

This boxplot shows 5 different forms of dancing, on the y axis we have the number of injuries. This is an ANOVA model. The question is, what assumptions could not be met according to this boxplot? I ...
0
votes
0answers
21 views

Non-numeric variables in regression [on hold]

I was wondering I am doing my econometric work and I wanted to ask. My data are about suicides. My variables are: (Number of suicides) = numeric (Year) = numeric (Sex) = 1=male, 0=female (dummy) (...
0
votes
0answers
23 views

Calculating odds ratio in Multiple select choice question analysis

I have a multiple response categorical variable (MRCV) and a single response categorical variable (SRCV). Respondents in my survey were presented with 6 choices (6 barriers to access an application) ...
1
vote
4answers
211 views

Regression with Lots of Categorical Variables

I'm facing a regression task with many categorical and few numeric features. I encoded them into dummies and removed the first dummy column for each feature. I am not getting very good R2 at all. I ...
0
votes
0answers
15 views

How to evaluate relationships with categorical variables?

I am working on the BigMart dataset. One of the variables has a substantial amount of missing values. I'd like to check whether these are missing completely at random. There are 12 variables, 4 are ...
0
votes
1answer
20 views

Analytical solution to the covariance between a continuous and a categorical variable

Let $X$ be a continuous variable with mean $\mu$ and $Y$ be a categorical variable with event probability vector $\mathbf{p}$. I am trying to calculate $Cov(X, Y)$. I have the solution if $\mathbf{p} ...
0
votes
1answer
17 views

Multiple nominal categories predicting a continuous variable

This is a simplified version of the problem that I'm having, but I'm really looking for the appropriate type of analysis for the question in which I'm interested. Set up: I have a large data set in ...
1
vote
1answer
36 views

Why does GBM package make different predictions for the same data point (after factor issue is fixed)?

I tried to use a GBM model to make predictions for the same data point, but it gave me very different answers. Please see the example below. When using the entire dataset for predicting the first data ...
0
votes
0answers
7 views

How to handle different input sizes of an NN when One-Hot-Encoding a categorical input?

let's assume an input dataset that is a mix of categorical values and real values. When preprocessing this data into an appropriate NN input, OHE is recommended because it doesn't assume any order of ...
0
votes
1answer
26 views

How to handle and test categorical dummy variables when interested only in certain levels?

I want to build a multiple linear regression model. I want to test the effect of a nominal variable with 10+ levels, but I am interested in testing only the effect of 2 of them. 1st Question: How ...
0
votes
1answer
16 views

testing whether categorical distributions differ

i have data on how a large population (N ~ 1e8) is distributed into (many) categories (i.e. i have count of instances in each category). some categories have low ...
1
vote
1answer
40 views

Hypothesis Testing: Is a Tool Better Than Random?

I am testing a tool that tries to select the correct outcome. I am trying to do significance testing to see if the tool is better then choosing the outcome at random. It picks from 4 categories, and ...
1
vote
0answers
31 views

How do I code the interaction between a continuous and a categorical variable in a meta-analysis?

I'm currently coding studies for my meta-analysis and I was wondering how I should code the interaction between a categorical variable (1 = private, 2 = public, 3 = misc [both]) and a continuous ...
0
votes
0answers
4 views

Categorical/Nominal Variables w/ Dependent Variable Ordinal: How to determine change over time

I am trying to run a statistical test to determine how four variables influenced moss mat reattachment rates in a removal experiment. In the experiment, we removed a 10x10 cm moss mat from a rock ...
3
votes
1answer
184 views

Should data be split into test / training prior to descriptive statistics being carried out on it?

I have a data set that I have added to and plan to carry out some modelling with. I'm wondering whether I should split the data into test / training prior to carrying out the modelling, or if I should ...
1
vote
1answer
29 views

Is rank a categorical variable or quantitative?

A product is rated 1 for poor and 10 for excellent. Does it strictly fall into either category - quantitative or categorical? (Although it seems like it is categorical, I was wondering if treating ...
0
votes
0answers
15 views

How many factors are there in EFA?

I have been adapting scale. CFA have not confirm structure. Therefore, I did EFA. EFA result showed that scale has four factor. But one factor has one or two item. How is this result interpreted? I ...
0
votes
1answer
26 views

Data Augmentation Techniques for Cat/Binary/Continuous Numerical Dataset

I am using the bank marketing dataset from the UCI ML repo to build an example of a big data storage system along with ETL workflows and Machine Learning models. I would like to create more data so I ...
0
votes
1answer
26 views

What post-hoc analysis should I use following a two-way ANCOVA with factor, integer and numeric variables?

I ran a two-way ANCOVA on the data below, in r-studio, to determine whether pupal weights Pupal.wt were affected by caterpillars' diet ...
0
votes
0answers
12 views

Controversiality metric

I am working with some data that needs to be labelled based on preference. Each user can cast one vote that places the item in one category, from 'totally dislike' to 'totally like' (there are 6 ...
0
votes
0answers
7 views

What test should I use to compare two categorical distributions with replicate measurements?

So I have data from an experiment I did, and I'm at a loss for which test I should use to assess for significance. I took some cells in vitro and subjected them to either a treatment or a control. ...
5
votes
2answers
90 views

Whether to use factors in R and when ordered factors?

I've done some searching on StackExchange and become more and more confused about using factors and ordered factors in R modeling. I've encountered several circumstances: A variable is characters ...
0
votes
0answers
25 views

Should I build a different model for each subset

I have a dataset which has categorical variable class and it has around 10 classes in it. I am trying to solve a regression problem I am not understanding whether I should build a model on entire ...
1
vote
1answer
30 views

Compositional Data and Machine Learning

One of my features is compositional of nature, represented by a vector [p1, p2, p3]. Each vector represents an emotion and each vector sums up to unity. Eg: ...
-1
votes
0answers
14 views

combining categorical variable in predictive model

Let's say we want to build a model with data which contains a categorical variable. If this categorical variable has a few distinct values then one-hot encoding will solve the problem, but in same ...
0
votes
0answers
22 views

Testing the goodness-of-fit for the binomial distribution

As specified in the title, I'm trying to understand how to test the goodness-of-fit for the binomial distribution; to this aim, I followed what suggested in this link. Particularly, I'm investigating ...
0
votes
0answers
8 views

Reordering a variable in the training and testing sets

I have a training set with 80% of the data and the testing set with the remaining 20%. I am fitting a GLM where one of the predictors is categorical with 5 different values. I was taught that a ...
0
votes
0answers
6 views

analyzing hierarchically grouped (selection) frequency data

I have a question regarding analyzing hierarchically grouped selection frequency data. (Disclaimer: I have never analyzed this type of data before. I did not think through the data analysis procedure (...
0
votes
0answers
25 views

Rank Ordered Logistic Regression

In an experiment, I have identified seven sensory parameters of lettuce. Examples are colour and texture. These were ranked by consumers in the order of most important to least important. I also ...
0
votes
0answers
31 views

Regression methods for ordered categorical data with more than 2 levels

I am dealing with an Outcome Variable y which is categorical (0,1,2,3) and ordered. My question is what type of regression models can I try for such a dataset ? I ...
0
votes
0answers
14 views

Identifying trends in mutually exclusive categorical variables

I'm posting here as I'm not even sure where to start Googling. Say I have a system that can be in one of three states – A, B, or C – and only one of these states when observed, which I do annually. A ...
-1
votes
0answers
17 views

Statistical test for independence of a sequence of behaviours

I collected data from a social experiment. The data consists of a set of interaction behaviours of the participants. Each participant can perform 2 behaviours, either A and B, and they can perform ...
-1
votes
0answers
15 views

Full Information Item Factor Analysis in R - how to maximize hyperplane count

I have 121 dichotomous items (n=550) that I'm trying to factor analyze using IRT methods. I've been given code for TestFact (and also SAS) but I'm hoping to do it in R. Are there any ways to adjust ...
0
votes
1answer
45 views

Multiple Regression in R with y as a Factor

I have a data set that rates customer satisfaction based on three options: Recommend Neutral Not satisfied I understand those may not be the best options but that's what I have to work with. Another ...
0
votes
0answers
11 views

Interpreting one hot encoded factors in logistic regressing [duplicate]

All my variables, both DV and IV, are categorical and I have to do the one-hot encoding. After I did the one-hot encoding, I am totally confused. What does the co-efficients mean? Lets say I have a DV ...
0
votes
0answers
24 views

Statistical Test According to Independent Variables

I wish to test a statistical significance between means of data groups. The groups are determined by a continuous variable, however this continuous variable is applied to different test subjects (...
0
votes
0answers
26 views

How Can I Test for Multicollinearity in my Categorical Predictor Variables when Doing Ordered Logistic Regression?

I have a dataset where my dependent variable measures 'How much Trump’s locker room video should have mattered in the election'. The categories are coded between 1-5, where 1 represents 'should not ...
0
votes
1answer
30 views

Any 'quick' way to test which of 50 variables affects 1 dependent variable?

I've very rusty with my statistics. I know I can test each one by one. But is there a quicker test? Specifically, I have a list of 300 clients with a "contact rate" (dependent variable). If I have ...
0
votes
0answers
20 views

Encoding variable number of categorical features

I have a dataset listing the software installed for each user. This dataset shall be used (in conjuction with other user datasets) to classify the user into 4 (imbalanced) categories. There are over ...
0
votes
2answers
35 views

Regression: Interactions terms of factors with several levels (interpretation)

I'm running the following linear model in R: lm(formula = Valence ~ StatusOfMandarin * Condition, data = d_afraid, na.action = na.omit) My data is as follow ...
0
votes
0answers
25 views

Statistical inference of a variable based on categorical respone levels.

Suppose that we have a variable $X$ with three levels $1$ ,$2$ and $3$ accordingly.Also we have a catergorical respone variable with two levels $Y=\left\{Healed,Not Healed\right\}$ which tells as if ...
0
votes
0answers
15 views

How to group text categorical data basis on clustering?

So if I have text dataset where I have more than 50 categories. Sample: ...
0
votes
1answer
19 views

Is it okay to combine dummy coding and sequence coding?

I have a model with two categorical variables. Each one has three levels. Iv1 has a natural reference category so I would like to use dummy coding, and compare level 2 to level 1, and level 3 to level ...
1
vote
1answer
18 views

Relationship between a categorical variable and a Bernoulli variable in R

I would like to answer the following question: What is the relationship between race and the likelihood of filing a state claim? Race is a categorical variable but since the response (...
1
vote
1answer
28 views

ICD10 (categorical) encoding

I am trying to figure out how best to encode ICD10 codes for input into a machine learning model. It isn't ordinal by any means, however, there is a sort of logic you can apply to just the labels ...