Category "r"

R crashed when plotting Lidar points with lidR

I had to re-downloaded the latest R and Rstudio with all previous packages deleted... Now I cannot plot 3D Lidar points with the lidR package, but plotting othe

Any packages for producing risk-of-bias assessment figures for the Joanna Briggs Institute's (JBI) critical appraisal tools?

I am conducting a meta-analysis. I am using JBI tools for the risk of bias assessment of the selected studies. Study types- randomized controlled trials, quasi-

what are these gray lines inside the bars of my ggplot bargraph?

I wanted to create a graph to show which continent has the highest co2 emissions total per capita over the years, so I coded this: barchart <- ggplot(data =

How to delete label above bar chart in R that's already in the legend?

this is my first post! Just wondering how to remove these titles above the charts: Here's the code for the diagram! I imagine I'll have to use something like:

R reticulate specifying python executable to use

First, I'm working on a Windows machine. I would like to specify a specific version of python to use in RStudio. I would like RStudio to use python 3 in the Arc

R reticulate specifying python executable to use

First, I'm working on a Windows machine. I would like to specify a specific version of python to use in RStudio. I would like RStudio to use python 3 in the Arc

python does not recognize R functions with ”.“ in the function name

When I call the contrasts.fit function in the R package, limma, I get an error, which I suspect is due to the "." reason, python may not recognize contrasts.fit

fancy pie chart in R using ggplot2

I have a pie chart below, and I would like to leave extra white space between each pie and paste the value of each letter in each pie (A=25). how to get around

Duplicate rows based on common value in other column?

I have a data frame which includes: one column having individual ID's (unique), and a second column showing a common unique variable. That is, everyone in colum

Bin a vector by width

I have a vector of a continuos variable. For example: x <- c(0.9000000, 1.2666667, 4.0000000, 5.7333333, 19.7333333, 35.7666667, 44.0000000, 4.4333333,

huxreg - exponentiated coefficients and updated standard errors

I am running some CRR models from the package cmprsk. I am working towards outputting the results using huxreg. I have used tidy_args to get exponentiated coeff

Match the column value of a dataframe to another, and if no match, the old value stays as it is

I have dataframe A like this: Sample1 Salmon Mouse Rooster Monkey My dataframe B is like below: Sample1 Sample2 Rooster Bird Mous

How to create a new column based on the value of another column while retaining the Date format

The data that I have is as: dt_1 cond1 2009-05-04 1 2009-07-04 0 I want to add a variable that has date from a existing variable, if cond1 is 1

How do I globally load Rmetric Financial calendars into `golem` at the startup?

Question: What are the best practices to go about setting a "global" financial calendar using load_rmetrics_calenders(), ie a singular run of a function in gole

R Shiny server dropbox connection works for sometime and then says "cannot connect to server" - error in drop_upload: Unauthorized (HTTP401)

I have used this code for a long time but I recently changed the dropbox account I wanted the .csv files to be sent to and now the app works, meaning you can op

Discard 200 random healthy instances

Discard 200 random healthy instances. How do I implement this in Rstudio? This is the data frame: https://www.kaggle.com/code/jamaltariqcheema/model-performance

Fill up missing values based on other entries on R

I have dataset input with a couple of missing values. and I have to create dataset output with the following logic: If there is a missing in any of the columns

Aggregate copublications associated with a primary publication

Each primary_citation may have multiple copublications. I would like to aggregate citation_id's associated with each primary citation. The following code works

crr output list- remove df$ from coefficients?

I am using the cmprsk package to create a series of regressions. In the real models I used, I specified my models in the same way that is shown in the example t

R: How can I add titles based on grouping variable in word_associate?

I am using the word_associate package in R Markdown to create word clouds across a grouping variable with multiple categories. I would like the titles of each w