# Data Science Stack Exchange Community Digest

## Top new questions this week:

### Multi-country model or single model

I am working on a ML model to be deployed in a product operating in many countries. The issue that I am having is the following: should I train one model and serve it for all countries? train a model ...

machine-learning linear-regression xgboost data-product

### One Hot Encoding for any kind of dataset

How can I make a one hot encoding for a unknown dataset which can iterate and check the dytype of the dataset and do one hot encoding by checking the number of unique values of the columns, also how ...

data python-3.x one-hot-encoding

### ETL and Data Engineering is it purely the knowledge of tools or is there theory behind it?

I would like to better understand what a good Data Englineer must know or what he does. Job descriptions mostly list tools that are required, such as Python. If it is possible to separate Data ...

data-analysis databases etl data-engineering structured-data

### Finding out why your model is doing better?

I fitted a logistic regression model on a data set and got an AUC score of .70. I added some additional out-hot encoded categorical features to the model and the AUC improved slightly to .74. How do I ...

machine-learning evaluation performance

### feature scaling xgbRegressor

I read for example in this answer: Does the performance of GBM methods profit from feature scaling? that scaling doesn´t affect the performance of any tree-based method, not for ...

machine-learning decision-trees xgboost normalization feature-scaling

### What Clustering Method Should I Use?

My data is a group of 10 thousand points (each having an node location (x,y)) that are spread across a plane. They are also chromatically-colored based on their weight. I need to finalize a bayesian ...

python clustering tsne bayesian-nonparametric

### Negatively correlated features

Is it ok to use negatively correlated features in data modeling? Say I have features A and B that have a correlation coefficient of 0.2 and features C and D with -0.2 correlation coefficient, is it ...

correlation
 answered by David Masip 1 vote

## Greatest hits from previous weeks:

### The cross-entropy error function in neural networks

In the MNIST For ML Beginners they define cross-entropy as $$H_{y'} (y) := - \sum_{i} y_{i}' \log (y_i)$$ $y_i$ is the predicted probability value for class $i$ and $y_i'$ is the true probability ...

machine-learning tensorflow

### DeprecationWarning: The 'categorical_features' keyword is deprecated in version 0.20

I was watching Machine Learning A- Z from SuperDataScience but when I was doing below code sample: import numpy as np import matplotlib.pyplot as plt import pandas as pd dataset = ...

machine-learning python scikit-learn

### I got the following error : 'DataFrame' object has no attribute 'data'

I am trying to get the 'data' and the 'target' of the iris setosa database, but I can't. For example, when I load the iris setosa directly from sklearn datasets I get a good result: Program: from ...

python pandas dataframe csv

### removing strings after a certain character in a given text

I have a dataset like the one below. I want to remove all characters after the character ©. How can I do that in R? data_clean_phrase <- c("Copyright © The Society of Geomagnetism and Earth", "© ...

r data-cleaning

### What does "linear in parameters" mean?

The model of linear regression is linear in parameters. What does this actually mean?

regression linear-regression

### How to plot two columns of single DataFrame on Y axis

i have two DataFrames(Action,Comedy). Action contains two columns(year,rating) ratings columns contains average rating with respect to year. Comedy Dataframe contains same two columns with different ...

python pandas graphs dataframe

### Confused about how to apply KMeans on my a dataset with features extracted

I am trying to apply a basic use of the scikitlearn KMeans Clustering package, to create different clusters that I could use to identify a certain activity. For example, in my dataset below, I have ...

python clustering k-means unsupervised-learning

## Can you answer these questions?

### 3d plot for clustering

I'm working on a cluster analysis project and was trying out different ways to plot clusters to explain the differences between the clusters. I did plot the different clusters in 2D. Can you please ...

python clustering matplotlib

### Finding optimal threshold in multi-class classification task

In a binary classification problem, it is easy to find the optimal threshold (F1) by setting different thresholds, evaluating them and picking the one with the highest F1. Similarly is there a proper ...

classification

### How to make a neural network generalizes better?

I designed a neural network model with large number of output predicted by softmax function. However, I want categorize all the outputs into 5 outputs without modifying the architecture of other ...

python neural-network pytorch