Questions tagged as 'r'

1
answer

How to group information in a data frame from missing data?

I need to exclude empty df rows from a 30-year time series, with three daily measurements for each variable. I already used the subset(x, ...) function that solves part of the problem. However, in some cases there is no recorded measureme...
asked by 27.03.2018 / 15:14
1
answer

OSMAR library error (OpenStreetMap)

Hello, I'm trying to use the OSMAR library in R to plot routes and I'm not getting it. library(osmar) library(leaflet) library(igraph) src <- osmsource_api() get_osm(node(18961430), source = src) The following error is appearing: Spa...
asked by 12.06.2018 / 02:49
1
answer

Shiny error when generating HTML

I'm trying to "create a probability calculator for Normal and Binomial distributions, but this is giving some error when it generates HTML." .Select the codes below. PS: Would it be possible to exchange mi and sigma for Greek letters?...
asked by 06.05.2018 / 15:04
1
answer

Join data frames

I have two date frames (see below) with consumption and gain information for animals. The consumption was collected every day and the gain in larger intervals. I want to join one next to the other, having a column of Animal, Day, Consumption and...
asked by 08.11.2017 / 15:31
1
answer

Get URL table in R

I need to do this here: library(xml) URL <- "http://globoesporte.globo.com/futebol/brasileirao-serie-a/" tabela1 <- readHTMLTable(URL, which = 1, colClasses = ) tabela1$V3 <- NULL names(tabela1) <- c("Posição","Time") tabela2...
asked by 09.11.2017 / 20:30
2
answers

Compare 2 Matrices and Return a Third (R)

The following arrays Matrix [,1] [,2] [,3] [,4] [,5] [1,] 0.228 0.285 0.285 0.285 0.380 [2,] 0.228 0.285 0.570 0.380 0.228 [3,] 0.380 0.285 0.228 0.380 0.285 [4,] 0.285 0.285 0.570 0.380 0.380 [5,] 0.380 0.228 0.285 0.285 0.380...
asked by 01.07.2014 / 16:38
1
answer

How to transform a sequence written in a numerical sequence? (R)

I'm having trouble handling a TSE bank. The part below the code imports it: library(tidyverse) locais_vot_SP <- read_delim("https://raw.githubusercontent.com/camilagonc/votacao_secao/master/locais_vot_SP.csv", locale...
asked by 25.04.2018 / 19:26
1
answer

How to get N-Points FFT in R?

Hi, I have a question about FFT, I'm looking for a similar method to numpy.fft.rfft . I would like to know if anyone knows an R method that calculates the N-Points FFT . The following is the code with only normal fft. link Python: im...
asked by 01.05.2018 / 15:45
1
answer

Stacked bar chart - Labels and Sorting - GGPLOT

I am constructing a graph indicating the population of the Brazilian states, organized by regions, according to the code below: State <- c("Rondônia", "Acre", "Amazonas", "Roraima", "Pará", "Amapá", "Tocantins", "Maranhão", "Piau...
asked by 12.10.2017 / 04:54
1
answer

How to change the scale of maps in ggplot2?

I'm making a map with ggplot and ggmap. However, the axis scales are in decimal degrees, but I need them in degrees, minutes, and seconds. Thanks for the help!     
asked by 15.08.2017 / 00:51