Step-by-Step Guide to Data Preprocessing in WEKA Using Labor Dataset
Data preprocessing is an essential step in the machine learning pipeline, helping to clean, organize, and prepare data for analysis. This…
Step-by-Step Guide to Data Preprocessing in WEKA Using Labor Dataset
Data preprocessing is an essential step in the machine learning pipeline, helping to clean, organize, and prepare data for analysis. This guide demonstrates how to perform preprocessing operations on the labor.arff dataset using WEKA Explorer. From loading the dataset to filtering attributes and discretizing numeric data, this tutorial offers a clear and practical walkthrough for beginners and practitioners alike.

WEKA
Step 1: Loading the Dataset
- Open WEKA Explorer.
- Navigate to the “Preprocess” tab.
- Click on the Open button and select the
labor.arfffile from your system. - Once loaded, WEKA scans the data, identifies attributes, and calculates basic statistics for each.
The left panel displays the list of recognized attributes, while the top panel shows the name of the relation (table). The current working relation initially matches the base relation.
Step 2: Viewing Attribute Statistics
Click on any attribute in the left panel to view its statistics:
- Categorical Attributes: The frequency distribution of each value is displayed.
- Numeric Attributes: Displays key metrics such as minimum, maximum, mean, and standard deviation.
The bottom-right panel provides a cross-tabulation visualization for two attributes. Use the dropdown menu to select different attributes for cross-tabulation.
Step 3: Selecting or Filtering Attributes
Removing an Attribute
To remove irrelevant or redundant attributes, follow these steps:
- Go to the Filter panel and click on the Choose button.
- In the popup window, select
weka.filters.unsupervised.attribute.Remove. - Click the textbox next to the Choose button to open the dialog box.
- Enter the index of the attribute to be removed. For example, if you want to remove the 7th attribute, enter
7. - Ensure the “Invert Selection” option is set to false.
- Click OK, then click Apply in the filter panel. This removes the specified attribute and creates a new working relation.
- Save the updated dataset by clicking the Save button and naming the file
labor.arff.
Step 4: Discretization of Numeric Attributes
Discretization is the process of converting continuous numeric attributes into discrete bins. This is often required for tasks like association rule mining.
Example: Discretizing the duration Attribute
- Load the
labor.arffdataset into WEKA. - Select the
durationattribute in the left panel. - In the Filter panel, click the Choose button and select
weka.filters.unsupervised.attribute.Discretize. - Click the textbox next to the Choose button to configure the filter:
- Enter the index of the attribute to be discretized (e.g.,
1forduration). - Set the number of bins to
3. - Leave all other settings as default.
-
Click OK to confirm.
-
Click Apply in the filter panel. The
durationattribute is now divided into three bins, creating a new working relation. -
Save the updated dataset as
labor-data-discretized.arff.
Sample Dataset: labor.arff

The following screenshot shows the effect of discretization

Conclusion
Preprocessing is an indispensable step in data analysis and machine learning. This tutorial demonstrated how to preprocess the labor.arff dataset in WEKA, including attribute filtering and discretization. These steps not only simplify the dataset but also improve its compatibility with specific algorithms. By following this guide, users can confidently handle preprocessing tasks for a variety of datasets.
Leverage WEKA’s user-friendly interface to explore, preprocess, and prepare your data efficiently for better analysis and modeling outcomes.
메타데이터
- post_id
- bd0cc7f22fa4
- slug
- step-by-step-guide-to-data-preprocessing-in-weka-using-labor-dataset-bd0cc7f22fa4
- url
- https://medium.com/@vignesh.slm666/step-by-step-guide-to-data-preprocessing-in-weka-using-labor-dataset-bd0cc7f22fa4
- canonical_url
- https://medium.com/@vignesh.slm666/step-by-step-guide-to-data-preprocessing-in-weka-using-labor-dataset-bd0cc7f22fa4
- author_url
- https://medium.com/@vignesh.slm666
- status
- ok
- fetched_at
- 2026-07-19 22:33:09