Description Usage Arguments Details Value See Also Examples
View source: R/tabulate_results.R
Función para tabular resultados de la elección (Function to tabulate election results)
| 1 | tabulate_results(data, LaTeX = F)
 | 
| data | un tibble guardado como objeto en el enviroment luego de consultar  | 
| LaTeX | parámetro para obtener código  | 
REQUISITOS:
1. El formato de data debe ser long para calcular resultados. 
Si data es wide se puede transformar con make_long 
(long format of data is required for getting results. 
If data is in wide format you can transform it with make_long)
2. data tiene que haber incorporando los nombres de las listas. Agreguelos con get_names
(data must have party names. Add them with get_names).
3. data tiene que haber sido descargada con parámetro level = provincia con la función 
get_election_data
(data must be level = provincia when downloading it with get_election_data).
Tabulado con resultados agregados de la eleccion. Por defecto devuelve un tabulado de class "gt_tbl" "list". Si en 
cambio el parametro es LaTex = TRUE devuelve codigo de LaTex con class"character" 
(Table with aggregated election results. By default it returns a tab of class 
 "gt_tbl" "list". If instead the parameter is set to LaTex = TRUE it returns LaTex code with class "character").
| 1 2 3 4 5 6 7 8 9 |  
 tucuman_dip_gral_2017
  
  x <- tucuman_dip_gral_2017 %>%
      get_names() %>% 
      tabulate_results(LaTeX = TRUE)
  
  cat(x)
  
 | 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.