Dealing with missing values
In this section, we are going to introduce the representation of missing values in R and ways to deal with them. Missing values can arise in many situations during data collection and analysis, either when the required information could not be acquired for some reason or when, due to certain circumstances, we would like to exclude some data from an analysis by marking them as missing. In the spatial data analysis context, it can be that some districts in an area we surveyed were inaccessible for data collection by the researcher or some parts of an aerial image were clouded and we could not digitize features of interest there.
Missing values and their effect on data
The special value that marks missing values in R is NA
. As briefly mentioned in the previous chapter, NaN
values represent cases when the resulting value cannot be represented within the real system number. NaN
values function in the same way as NA
in all respects that are relevant here.
The same way...