Questions tagged [r]
R is a free, open-source programming language & software environment for statistical computing, bioinformatics, visualization & general computing. Please use minimal reproducible examples others can run using copy & paste. Show desired output entirely. Use dput() for data & specify all non-base packages with library(). Don't embed pictures for data or code, use indented code blocks instead. For statistics questions, use https://stats.stackexchange.com.
508,402
questions
3
votes
1
answer
40
views
Keep ggplot font size constant in different figure dimensions
I'm in a position that requires me to frequently change the dimensions of my plots via the fig.dim=c(...,...) option in each r chunk.
However, I have a problem that I haven't been able to solve yet.
...
0
votes
0
answers
29
views
Issue with Residual Plot Pattern after Fitting beta_family Model in glmmTMB
I'm working with proportion data and have tried several models to address issues of overdispersion and underdispersion. Initially, I used a binomial distribution model which showed overdispersion. ...
0
votes
0
answers
11
views
Grab the user details when a user authenticates an R shiny web app using Azure Active Directory
I am new to the concept of web apps deployed in Azure and related authentications.
I have an R Shiny app, hosted as an app service in Azure cloud using Docker containers. I have few Azure user groups ...
0
votes
0
answers
27
views
Merging PISA 2000 student file with ESCS index file [duplicate]
I am using PISA data from 2000, 2003 & 2018. I am using the ESCS index. For 2000, the ESCS index is not included in the student file and has to be merged with the student file. However, I load ...
0
votes
1
answer
44
views
Table disappearing if inputting special characters [closed]
I am using reactable with custom filtering and regular expression patterns, like in this example:
https://glin.github.io/reactable/articles/custom-filtering.html#regular-expression-pattern-filtering
...
0
votes
0
answers
13
views
Error when using diagnose function from glmmTMB
I'm using glmmTMB (version 1.1.9) to run a step selection analysis with the two-step approach suggested by Muff et al. 2020 (fitting a Poisson model specifying a stratum-specific fixed intercept) ...
1
vote
5
answers
95
views
How to count the total entries by group when they are comma-separated
I'm working with the League of Legends Champions dataset
name
tags
Aatrox
Fighter
Ahri
Mage,Assassin
Akali
Assassin
Akshan
Marksman,Assassin
Alistar
Tank,Support
And I was wondering how to ...
1
vote
1
answer
44
views
Creating a large number of columns in R tidyverse based on a comparison with a specific column
I have a dataset in R tidyverse and I want to create 192 columns based on comparison with the sp column, just like the mp_comp_1 column. How can I do this for 192 columns in tidyverse?
library(...
-1
votes
0
answers
58
views
Interpunct (middle dot) in R [closed]
What is the meaning of an interpunct (middle dot, https://en.wikipedia.org/wiki/Interpunct) in R?
After some troubleshooting with column names that were thought to be identical across dataframes but ...
1
vote
1
answer
21
views
How to Add Significance bars a Bar Plot that have percentage/logical data
I have a dataframe with a categorical variable and a few logical variables. I’ve created an example using the iris dataset:
# Create a new dataframe showing the percentage each variable that is ...
0
votes
0
answers
49
views
Why Does Native Pipe Operator |> Fail with Placeholder _ in R? [duplicate]
I am trying to compare the %>% with the native |>, but I am not too sure why sometimes it only works for %>%. Here is an example:
library(magrittr)
library(stringr)
# Create the sample ...
1
vote
2
answers
53
views
Pattern matching in a dataframe
I am having some trouble conducting pattern matching within a data frame. I am working with grepl function in R.
I have a data frame of 5 local districts in two years (2001 and 2002). I want to check ...
1
vote
6
answers
65
views
Divide one column to three add fill up missing numbers
That's a part of my data:
structure(list(Testa = c(-1L, -1L, -1L,
-1L, -1L, -1L, -1L, -1L), Pre = c(NaN, NaN, NaN,
...
0
votes
1
answer
17
views
How to validate multivariate linear model using split half analysis or cross validation? [closed]
I created a multivariate linear model and am wondering how I can validate the model? The samples are environmental samples and due to a few limitations I am not able to validate by collecting more ...
0
votes
1
answer
25
views
Trying to make a heatmap based on percentage values from zip code area [closed]
I've been trying to use the choroplethrZip package to do this based on a previous post, but my version of R will not support this package. I'm using the data set and code below, and believe I have it ...