title: Error in seq.int(0, to0 - from, by) : wrong sign in 'by' argument
body: <p>I'm trying to create a long tibble dataframe with a date sequence. Now I tried to use this <a href="https://stackoverflow.com/a/46248539/5816847">example</a>. The example works but not when I try to implement to my own data. It gives an error message: <code>Error in seq.int(0, to0 - from, by) : wrong sign in 'by' argument</code>. At can't figure out why the code on my <code>tibble</code> throws an error... All help much appreciated.</p>
  
  <p>This example works:</p>
  
  <pre><code>library(tidyverse)
  
  example &lt;- structure(list(idnum = c(17L, 17L, 17L), start = structure(c(8401, 
  8401, 8401), class = "Date"), end = structure(c(8765, 8765, 8765
  ), class = "Date")), class = "data.frame", .Names = c("idnum", 
  "start", "end"), row.names = c(NA, -3L)) 
  
  example %&gt;%
    as.tibble() %&gt;%
    nest(start, end) %&gt;% view
    mutate(data = map(data, ~seq(unique(.x$start), unique(.x$end), 1))) %&gt;%
    unnest(data)
  </code></pre>
  
  <p>That's kind of what I'm looking for.</p>
  
  <p>The code on my data gives an error message.</p>
  
  <pre><code>df &lt;- structure(list(nieuw = c("Nieuw", "Nieuw", "Nieuw"), jaar = c(NA, 
  2013, 2014), aow_jaar = c("65", "65", "65"), aow_maanden = c(NA, 
  "1", "2"), vanaf = structure(c(-8036, -8036, -7701), class = "Date"), 
      tot_en_met = structure(c(-8037, -7702, -7367), class = "Date")), class = c("tbl_df", 
  "tbl", "data.frame"), row.names = c(NA, -3L))
  
  df %&gt;%
    nest(vanaf, tot_en_met) %&gt;%
    mutate(data = map(data, ~seq(unique(.x$vanaf), unique(.x$tot_en_met), 1))) %&gt;%
    unnest(data)
  </code></pre>
  
  <p><code>Error in seq.int(0, to0 - from, by) : wrong sign in 'by' argument</code></p>
  
  <p>The error message say it has to do with the <code>by =</code> argument but I can't understand why it's not working...</p>