Tagged articles
13 articles
Page 1 of 1
Code Mala Tang
Code Mala Tang
Mar 29, 2025 · Fundamentals

Better Ways to Handle Missing Values in Python Instead of Returning None

This article explains why returning None for missing values can cause unexpected errors in Python code and presents five practical alternatives—including default values, raising exceptions, special objects, type‑hinted optional returns, and dataclasses—to handle absent data safely and cleanly.

Default ValuesPythondataclasses
0 likes · 4 min read
Better Ways to Handle Missing Values in Python Instead of Returning None
Python Programming Learning Circle
Python Programming Learning Circle
Dec 31, 2022 · Artificial Intelligence

A Beginner’s Guide to Data Preprocessing for Machine Learning in Python

This tutorial walks beginners through the essential steps of data preprocessing for any machine learning model, covering library imports, dataset loading, handling missing values, encoding categorical features, splitting into train‑test sets, and applying feature scaling using Python’s scikit‑learn.

Pythondata preprocessingfeature scaling
0 likes · 11 min read
A Beginner’s Guide to Data Preprocessing for Machine Learning in Python
Python Programming Learning Circle
Python Programming Learning Circle
Feb 28, 2022 · Artificial Intelligence

Time Series Data Preprocessing: Missing Value Imputation, Denoising, and Outlier Detection

This article explains essential time series preprocessing techniques—including data sorting, handling missing values with interpolation methods, applying rolling averages, Fourier transform denoising, and detecting anomalies using rolling statistics, isolation forests, and K‑means clustering—illustrated with Python code on the AirPassengers and Google stock datasets.

DenoisingPythonTime Series
0 likes · 9 min read
Time Series Data Preprocessing: Missing Value Imputation, Denoising, and Outlier Detection
Python Programming Learning Circle
Python Programming Learning Circle
Dec 18, 2020 · Fundamentals

Data Exploration and Cleaning: Core Concepts, Steps, and Example Workflow

This article explains the purpose of data exploration and cleaning, outlines core analysis tasks, details missing‑value and outlier handling techniques—including various imputation methods—and illustrates the complete workflow with example images and a histogram‑based distribution analysis.

data cleaningdata explorationdata preprocessing
0 likes · 3 min read
Data Exploration and Cleaning: Core Concepts, Steps, and Example Workflow
Meituan Technology Team
Meituan Technology Team
Aug 15, 2019 · Big Data

Inconsistent Predictions in XGBoost on Spark Due to Different Missing Value Handling

The discrepancy between XGBoost’s Java engine and Spark arose because XGBoost4j treats zero as the default missing value while Spark’s sparse vectors use NaN, causing inconsistent predictions, and was resolved by explicitly setting Float.NaN as the missing value or converting sparse vectors to dense so both engines handle zeros uniformly.

SparkSparseVectorXGBoost
0 likes · 13 min read
Inconsistent Predictions in XGBoost on Spark Due to Different Missing Value Handling