Running examples in 'MixviR-Ex.R' failed
The error most likely occurred in:

> ### Name: create_ref
> ### Title: Create MixVir-formatted reference genome object
> ### Aliases: create_ref
> ### Keywords: reference
> 
> ### ** Examples
> 
> site1 <- "https://raw.githubusercontent.com/mikesovic/MixviR/main/raw_files/GCF_ASM985889v3.fa"
> site2 <- "https://raw.githubusercontent.com/mikesovic/MixviR/main/raw_files/sars_cov2_genes.bed"
> 
> if (httr::http_error(site1) | httr::http_error(site2)) {
+      message("No internet connection or data source broken.") 
+      return(NULL)
+ } else { 
+ create_ref(
+  genome = site1,
+  feature.bed = site2,
+  code.num = "1")
+ }
Rows: 12 Columns: 6
── Column specification ────────────────────────────────────────────────────────
Delimiter: "\t"
chr (4): X1, X4, X5, X6
dbl (2): X2, X3

ℹ Use `spec()` to retrieve the full column specification for this data.
ℹ Specify the column types or set `show_col_types = FALSE` to quiet this message.
trying URL 'https://raw.githubusercontent.com/mikesovic/MixviR/main/raw_files/GCF_ASM985889v3.fa'
Content type 'text/plain; charset=utf-8' length 30290 bytes (29 KB)
==================================================
downloaded 29 KB

Error in `dplyr::summarise()`:
ℹ In argument: `translation = translate_fwd(REF_BASE, code = code.num)`.
ℹ In group 1: `GENE = "E"`.
Caused by error:
! `translation` must be size 1, not 228.
ℹ To return more or less than 1 row per group, use `reframe()`.
Backtrace:
     ▆
  1. ├─MixviR::create_ref(genome = site1, feature.bed = site2, code.num = "1")
  2. │ └─... %>% dplyr::pull(translation)
  3. ├─dplyr::pull(., translation)
  4. ├─dplyr::arrange(., GENE, POS)
  5. ├─dplyr::summarise(...)
  6. ├─dplyr:::summarise.grouped_df(...)
  7. │ └─dplyr:::summarise_cols(.data, dplyr_quosures(...), by, "summarise")
  8. │   └─base::withCallingHandlers(...)
  9. ├─dplyr:::dplyr_internal_error(...)
 10. │ └─rlang::abort(class = c(class, "dplyr:::internal_error"), dplyr_error_data = data)
 11. │   └─rlang:::signal_abort(cnd, .file)
 12. │     └─base::signalCondition(cnd)
 13. └─dplyr (local) `<fn>`(`<dpl:::__>`)
 14.   └─dplyr (local) handler(cnd)
 15.     └─rlang::abort(message, class = error_class, parent = parent, call = error_call)
Execution halted