Germany quotation marks broken in tinytex/rmarkdown - even when using package...
What I want:I'd like to have German quotation marks in my TeX-PDF via rmarkdown and tinytex on MacOS (Catalina). See for example:The problem:It used to work following the guidelines as proposed here....
View ArticleAPI in R & Ravelry
I'm trying to use the Ravelry API to do some data analysis and I'm having difficulties. I'm modeling my code after this link but I'm afraid this blog may have been written before there were different...
View ArticleWhat is the coordinate system, projection, and Geoid for geocoding in ggmap api?
What is the coordinate system, projection, and Geoid for geocoding ggmap api?
View ArticleIs there a workaround for this failure to dodge in geom_violin?
If a data set includes at least three data points per cell, the dodging of violins works as expected. See the image below.Dodge is as expeced However, in the code that follows, there are only 2 data...
View ArticleWill Docker suffice for a Shiny app with ~100 connections or do I need Shiny...
I'm looking for a free and open source option for serving out a Shiny appl to ~100 of my students simultaneously. I tried to do this with Shiny Server Open and it throttled. Users got a message likeToo...
View ArticleQuantstrat: apply.paramset fails due to combine error for certain paramater...
For some reason when I adjust the paramater distributions for apply.paramaset to include more extreme values beyond about -250I get a simpleError sayingmatch.names(clabs,names(xi)) names do not match...
View ArticleError in either `/` or round functions from base R [duplicate]
I have been trying to make a contribution to the data.table package by adding the round function to the ITime class, when i came across a rather odd discrepancy produced by the round function. Behind...
View ArticleR ggplot2 using italics and non-italics in the same category label
For my ggplot figure, I want to label categories on a barplot with the first word being italicized, while the following words are non-italicized. I want the category labels to look like...
View ArticleR: Create new column by finding all numbers that are more or less than...
I have the following dfdf <- structure(list(position = c(44188968, 44188969, 44188970, 44188975, 44188977, 44188978), code1 = c(1, 0, 1, 0, 0, 1)), class = "data.frame", row.names = c(NA, -6L))...
View ArticleHow to set empty body in httr get request (?
How do I set an empty body for my get request without leaving out the Body parameter?See the following example:url <-...
View ArticleHow to obtain percentile of variable and the rate of dummy for all
How to do this for all columns of the object x automatically, using base R or SAS base. Here is example using R:# sample data set.seed(123) x <- data.frame(var1=runif(100), var2=runif(100),...
View ArticleRStudio not showing code in Rmd file, while Notepad does
I'm currently running into an issue of a .Rmd file opening in RStudio without actually populating the Source pane with the code. The file was written in RStudio, and the code shows up when I open the...
View ArticleHow To Make a Customized Function To Print Out Accordingly To Plots In R ggplot
I wonder if there is a way to automatically calculate mean of one group / mean of another group and prints the result to the plot like in the attached image. I also want the bigger number to go the...
View ArticleHigh Dimensional Array
I have a 13 dimensional array: MatrixQ<-array(0,dim=c(2,2,2,2,2,2,2,2,2,2,2,2,3))How can I refer to ith dimension of it in a loop?for (i in 1:13) { I want to assign the number i to the ith dimension...
View ArticleOAuth2 authentication with R using httr
I am trying to read some data from Polar Accesslink API. I have read their documentation and examples (Python, not that familiar with it) as well as httr examples/demos of...
View ArticlePlotting 4 plots on 1 page, with a common legend in R
I have the following plot:dat <- data.frame( FunctionClass = factor(c("A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "Y", "Z"),...
View ArticleHow to continue a loop when NA/NaN/Inf error occurs in depmixS4 HMM fitting?
code: for(j in 1:100){...... for(k in 1:20) { fit.mod = fit(mod) if(AIC(fit.mod) < best) { best_model = fit.mod best = AIC(fit.mod) } fit.mod <- best_model ........} when the error Error in...
View ArticleHow can I sum the unique values in a variable by the observations in another...
I have a dataset containing information on hospital visits for certain years. One of the variables contains county codes for counties that the visits occurred in and another variable contains the year...
View ArticleRead SPSS file into R, the data format for date is wrong, and generate more...
I have tried using spss.get from Hmisc. Here is my code: install.packages("Hmisc") library(Hmisc) mydata <- spss.get("C:\\good good study\\comscore\\purchase.sav", use.value.labels = TRUE) the...
View ArticleWhat are the differences between vector and list data types in R?
What are the main differences between vector and list data types in R? What are the advantages or disadvantages of using (or not) these two data types?I would appreciate seeing examples that...
View Article