Note: This page has been translated by MathWorks. Click here to see

To view all translated materials including this page, select Country from the country navigator on the bottom of this page.

To view all translated materials including this page, select Country from the country navigator on the bottom of this page.

Remove missing entries

`R = rmmissing(A)`

`R = rmmissing(A,dim)`

`R = rmmissing(___,Name,Value)`

```
[R,TF] =
rmmissing(___)
```

removes
missing entries from an array or table. If `R`

= rmmissing(`A`

)`A`

is
a vector, then `rmmissing`

removes any entry that
contains missing data. If `A`

is a matrix or table,
then `rmmissing`

removes any row that contains missing
data. Missing values are defined according to the data type of `A`

:

`NaN`

—`double`

,`single`

,`duration`

, and`calendarDuration`

`NaT`

—`datetime`

`<missing>`

—`string`

`<undefined>`

—`categorical`

`' '`

—`char`

`{''}`

—`cell`

of character arrays

specifies
additional parameters for removing missing entries using one or more
name-value pair arguments. For example, you can use `R`

= rmmissing(___,`Name,Value`

)`rmmissing('MinNumMissing',n)`

to
remove rows that contain at least `n`

missing values.

`fillmissing`

| `ismissing`

| `isnan`

| `isnat`

| `standardizeMissing`

Was this topic helpful?