Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix recent error with plotly : Prevents any plots -> .html from being made #9

Open
ppreshant opened this issue Mar 20, 2024 · 3 comments
Labels
bug Something isn't working

Comments

@ppreshant
Copy link
Owner

ppreshant commented Mar 20, 2024

Error when analysis.R with q54_S079-RNA2_Travis-1-5_RAM.xls file. The empty string after '40-CT' is the issue, not the plot title!

processing file: make_html_plots.rmd
  |....      |  38% [cq_plt]      
Quitting from lines 32-42 [cq_plt] (make_html_plots.rmd)
Error in `train()`:
! unused argument (list("q54_S079-RNA2_Travis-1-5_RAM", "40 - Cq", "40 - CT", "", "Sample_category"))
Backtrace:
 1. plotly::ggplotly(horz.cq)
 2. plotly:::ggplotly.ggplot(horz.cq)
 3. plotly::gg2list(...)
 4. plotly:::get_gdefs_ggproto(npscales$scales, theme, plot, layers)
 5. guides$train(scales, theme$legend.direction, plot$labels)
Warning messages:
1: In class(fl$Results$CT) <- "numeric" : NAs introduced by coercion
2: Removed 11 rows containing
missing values or values outside
the scale range (`geom_point()`). 
3: Removed 11 rows containing
missing values or values outside
the scale range (`geom_point()`). 
4: Removed 11 rows containing
missing values or values outside
the scale range (`geom_point()`). 
5: Removed 11 rows containing
missing values or values outside
the scale range (`geom_point()`). 
6: Removed 11 rows containing
missing values or values outside
the scale range (`geom_point()`). 
7: Removed 11 rows containing
missing values or values outside
the scale range (`geom_point()`). 
8: Removed 11 rows containing
non-finite outside the scale
range (`stat_boxplot()`). 
9: Removed 11 rows containing
missing values or values outside
the scale range (`geom_point()`).
@ppreshant ppreshant added the bug Something isn't working label Mar 20, 2024
@ppreshant
Copy link
Owner Author

Why is the title of the plot appearing along with other stuff (from a sample renamer presumably?)
unused argument (list("q54_S079-RNA2_Travis-1-5_RAM", "40 - Cq", "40 - CT", "", "Sample_category"

@ppreshant
Copy link
Owner Author

Does the ggplotly fail due to missing y_axis label -> if an empty string is used
(after some update?)

Couldn't reproduce this with a simple plot

a <- tibble(a1 = 1:5, a2 = a1^2)

plt <- {ggplot(a, aes(a1, a2)) + geom_point()  + 
    
    list(
    labs(title = 'tst'), xlab('ants'), ylab('')
    )
  
    } %>% print

ggplotly(plt) # this works fine 😞 ; even with ylab(NULL)

@ppreshant
Copy link
Owner Author

No 😞 : Is this fixed if you add back a y axis label? since plot is flipped, this would be xlab(..).

  • Also same error with plt.cq (that is not coord flipped as well)
tst <- horz.cq + xlab('dymmmy')
ggplotly(tst)
Error in train(..., self = self) : 
  unused argument (list("40 - CT", "q54_S079-RNA2_Travis-1-5_RAM", "40 - Cq", "dymmmy", "Sample_category"))```

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant