Learn R Programming

inpdfr (version 0.1.5)

doCA: Performs a correspondance analysis on the basis of the word-occurrence data.frame.

Description

Performs a correspondance analysis on the basis of the word-occurrence data.frame using ca function.

Usage

doCA(wordF, getPlot = TRUE, mwidth = 800, mheight = 800,
  formatType = "png", ...)

Arguments

wordF

The data.frame containing word occurrences.

getPlot

If TRUE, save the ca plot in the RESULTS directory.

mwidth

The width of the plot in pixels.

mheight

The height of the plot in pixels.

formatType

The format for the output file ("eps", "pdf", "png", "svg", "tiff", "jpeg", "bmp").

...

Additional arguments from the ca function.

Value

The results of the ca function.

Examples

Run this code
# NOT RUN {
data("loremIpsum")
loremIpsum01 <- loremIpsum[1:100]
loremIpsum02 <- loremIpsum[101:200]
loremIpsum03 <- loremIpsum[201:300]
loremIpsum04 <- loremIpsum[301:400]
loremIpsum05 <- loremIpsum[401:500]
subDir <- "RESULTS"
dir.create(file.path(getwd(), subDir), showWarnings = FALSE)
write(x = loremIpsum01, file = "RESULTS/loremIpsum01.txt")
write(x = loremIpsum02, file = "RESULTS/loremIpsum02.txt")
write(x = loremIpsum03, file = "RESULTS/loremIpsum03.txt")
write(x = loremIpsum04, file = "RESULTS/loremIpsum04.txt")
write(x = loremIpsum05, file = "RESULTS/loremIpsum05.txt")
wordOccuDF <- getwordOccuDF(mywd = paste0(getwd(), "/RESULTS"), excludeSW = FALSE)
file.remove(list.files(pattern = "loremIpsum"))
doCA(wordF = wordOccuDF)
# }

Run the code above in your browser using DataLab