Statistics and Machine Learning Toolbox™는 두 가지 추가 데이터형을 제공합니다. nominal
데이터형과 ordinal
데이터형을 사용하여 순서가 있는 비수치적 이산 데이터와 순서가 없는 비수치적 이산 데이터를 다룹니다. dataset
배열 데이터형을 사용하여 데이터형이 각각 다른 변수를 포함한 여러 변수를 단일 객체에 저장합니다. 그러나, 이러한 데이터형은 Statistics and Machine Learning Toolbox만의 고유한 데이터형입니다. 더 나은 제품 간 호환성을 제공하기 위해, 각각 MATLAB®에서 제공되는 categorical
데이터형 또는 table
데이터형을 사용하십시오. 자세한 내용을 보려면 categorical형 배열 생성하기 항목과 테이블을 생성하고 사용하기 항목을 참조하거나 테이블과 categorical형 배열 비디오를 참조하십시오.
dataset | (Not Recommended) Arrays for statistical data |
Nominal and ordinal arrays store data that have a finite set of discrete levels, which might or might not have a natural order.
Advantages of Using Nominal and Ordinal Arrays
Easily manipulate category levels, carry out statistical analysis, and reduce memory requirements.
Grouping variables are utility variables used to group or categorize observations.
Dummy variables let you adapt categorical data for use in classification and regression analysis.
Other MATLAB Functions Supporting Nominal and Ordinal Arrays
Learn about MATLAB functions that support nominal and ordinal arrays.
Create Nominal and Ordinal Arrays
Create nominal and ordinal arrays using nominal
and
ordinal
, respectively.
Categorize numeric data into a categorical ordinal array using
ordinal
.
Change the labels for category levels in nominal or ordinal arrays using
setlabels
.
Add and drop levels from a nominal or ordinal array.
Merge categories in a nominal or ordinal array using
mergelevels
.
Reorder the category levels in nominal or ordinal arrays using
reorderlevels
.
Determine sorting order for ordinal arrays.
Plot data grouped by the levels of a categorical variable.
Summary Statistics Grouped by Category
Compute summary statistics grouped by levels of a categorical variable.
Test Differences Between Category Means
Test for significant differences between category (group) means using a t-test, two-way ANOVA (analysis of variance), and ANOCOVA (analysis of covariance) analysis.
Index and Search Using Nominal and Ordinal Arrays
Index and search data by its category, or group.
Linear Regression with Categorical Covariates
Perform a regression with categorical covariates using categorical arrays and
fitlm
.
Dataset arrays store data with heterogeneous types.
Create a Dataset Array from Workspace Variables
Create a dataset array from a numeric array or heterogeneous variables existing in the MATLAB workspace.
Create a Dataset Array from a File
Create a dataset array from the contents of a tab-delimited or a comma-separated text, or an Excel file.
Add and delete observations in a dataset array.
Add and delete variables in a dataset array.
dataset형 배열 변수와 변수의 데이터를 사용해서 작업을 수행합니다.
Select Subsets of Observations
Select an observation or subset of observations from a dataset array.
Sort Observations in Dataset Arrays
Sort observations (rows) in a dataset array using the command line.
Merge dataset arrays using join
.
Stack or Unstack Dataset Arrays
Reformat dataset arrays using stack
and unstack
.
Find, clean, and delete observations with missing data in a dataset array.
Calculations on Dataset Arrays
Perform calculations on dataset arrays, including averaging and summarizing with a grouping variable.
Export a dataset array from the MATLAB workspace to a text or spreadsheet file.
Dataset Arrays in the Variables Editor
The MATLAB Variables editor provides a convenient interface for viewing, modifying, and plotting dataset arrays.
Index and Search Dataset Arrays
Learn the many ways to index into dataset arrays.
Regression Using Dataset Arrays
This example shows how to perform linear and stepwise regression analyses using dataset arrays.