Description Usage Arguments Value Examples
This function reformats the data for its use with Election Forensics Toolkit.
1 | eftFormatter(x, Nvalid = "CEC", levels = TRUE)
|
x |
the object from Databuilder/DataMerger function. |
Nvalid |
valid votes computed using either "CEC" (using the Central Election Comission's formula); "AllVotes" (total number of votes cast for all candidates). |
levels |
add information on levels (TRUE) or not (FALSE) to the output. |
Returns the data.frame object with three variables: "Votes" (number of ballots for the leading parties or candidates), "Nvalid" (number of casted ballots), "Voters" (number of eligible voters).
1 2 3 4 5 6 7 8 9 10 | library(CECscraper)
murl <- "http://notelections.online/region/izbirkom?action=show&vrn=27720002327736®ion=77&prver=0&pronetvd=null"
uiks <- listURLextractor(
rowURLextractor(
listURLextractor(
listURLextractor(murl))[1:5,], 'sayt izbiratel`noy komissii sub`yekta'))
uiks_voting <- rowURLextractor(uiks, "Rezul`taty vyborov|vyborov po odnomandatnomu \\(mnogomandatnomu\\) okrugu")
uiks_voting_data <- dataBuilder(uiks_voting, bylevel="level1", ttime=FALSE)
uiksEFT <- eftFormatter(uiks_voting_data)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.