I have a big data.frame called \"mat\" of 49952 obs. of 7597 variables and I\'m trying to replace NAs with zeros. Here is and example how my data.frame looks like:
#install.packages("xlsx")
library(xlsx)
extracted_df <- read.xlsx("test.xlsx", sheetName='Sheet1', stringsAsFactors=FALSE)
# Replace all NAs in a data frame with "G" character
extracted_df[is.na(extracted_df)] <- "G"