Questions tagged as 'r'

1
answer

Extract weights / weights in ACP / PCA psych :: main

I am conducting a Principal Components Analysis (ACP) in R to summarize the monthly correlation patterns found in 30 sampled regions. To do this, I am using as input an array of 10 (months) x 30 (regions) -download here -. At first I was worki...
asked by 26.04.2018 / 16:56
1
answer

Create data.table and export to txt

The final goal is to create a txt where each row is different. For this I have different variables with different values that are going to be combined. The solution I provide does not seem the most appropriate because if the number of values is...
asked by 24.05.2018 / 16:27
1
answer

R: Import maps shapefile format to R

With these packages: library(readr) library(leaflet) library(magrittr) library(ggmap) library(ggrepel) I would like to be able to put these putos on a map with greater relief following this script...
asked by 15.02.2018 / 13:38
1
answer

Using a for in R to generate a table of coin releases

Reviewing the exercises for loops of this site link I was curious about number 5: "Use a for loop to simulate 20 coin tosses 20 times, recording the results (1 = heads, 0 = tails) in a pre-set vector" (own translation) The solution pr...
asked by 12.04.2018 / 22:01
1
answer

R: Rotate x-axis labels in a barplot

I wanted to know how to tilt (certain degrees to the right) the axis labels x of a barplot . When I run the script of barplot : barplot(Indexpercentage, horiz = FALSE, col = c("Green","Orange","Red","Blue"), be...
asked by 20.12.2017 / 17:39
1
answer

Sort in R based on criteria

I would like to learn how to order a dataframe (List_Habitat) depending on your own criteria. List_habitat: Specie Habitat Amaranthus Crop Apiaceae Edge Asteraceae Quercus Malvaceae Wasteland...
asked by 10.11.2017 / 15:57
2
answers

How to create a bwplot in lattice

I'm just going through my adventure with R and I still have many doubts. I would like to create a bwplot of the 5 subsets that I have but I have no idea how to do it. I want to compare variables RealInv and RealGNP . It is...
asked by 26.11.2017 / 18:45
1
answer

Graph in 3d an lm

I have a factorial experimental design which I want to graph. I do: LmA<-lm(z ~ (x+ I(x^2)+y+I(y^2)+I(y*x)), data=dudagrafico) summary(LmA) and so I get the formula of the model. I would like to make a graphic of this style: Here i...
asked by 06.01.2018 / 20:08
2
answers

Adjustment of sigmoidal growth curves in R

I am trying to adjust a curve of accumulation of nutrients and dry matter of corn in R. I know that the curve that it describes is sigmoidal and that the accumulation of dry matter or nutrients depends on time. My first question is how I adjust...
asked by 04.11.2017 / 21:09
1
answer

Convergence failure in curve fitting by nls

I'm trying to fit a sigmoidal curve to several data sets, so I'm using this script: plotPoints (MS ~ Day, data = dataT1) MST1 <- nls(y ~ a + ((b - a)/(1 + exp(-c * (x - d)))), data = dataT1, start = list(a = min(data...
asked by 06.11.2017 / 16:34