Climate data in R with the raster package Jacob van Etten.

Slides:



Advertisements
Presentaciones similares
Ser vs Estar.
Advertisements

Mr. Redaelli OnlineTaco.com. To Have - Tener Yo tengo – I have Tú tienes – You have (Informal) Usted tiene – You have (Formal) El tiene – He has Ella.
Negatives and Questions. Negatives Consider the following sentences: Juan estudia mucho. Marta y Antonio viven en Georgia. Rita y el chico necesitan.
What time is it? DLT: I can tell time in Spanish..
Instructions for using this template. Click on the point value you want and say the name of the food shown. Once you’ve gotten to the answer, click the.
Conjugating AR verbs What is an –AR verb?. First, let’s talk about verbs… What is an infinitive? The basic form of a verb Means “to do something” Has.
Negative Commands of Regular Verbs. Forming negative formal commands of regular verbs is fairly simple. Write the formal (Ud.) form command of the verb,
Using Gustar Avancemos Level 1. Help me fill in the grid with Spanish pronouns.. Yo Tú Él, Ella, Usted Nosotros/as Ellos, Ellas, Ustedes X.
-AR Verbs In Spanish, there are three classes (or conjugations) of verbs: those that end in –AR, those that end in –ER, and those that end in –IR. This.
How to Conjugate Regular –AR Verbs in the Present Tense.
How to Conjugate Regular –AR – Er - IR Verbs in the Present Tense.
Formal Commands of Regular Verbs
Indirect Object Pronouns
What has to be done today? It can be done in any order. Make a new ALC form Do the ALC Get two popsicle sticks Get 16 feet of yarn. That is 4 arms width.
Los verbos reflexivos Objective:
ESPAÑOL 1 UNIDAD 4: Computer lab day
Unit 2A: Lesson 2 How to Talk About Your Schedule Gramática- Present tense of –ar verbs.
Definition
Mi dormitorio My bedroom
¿Qué haces en la escuela? Question words, objects, yo-go’s.
Las Preguntas (the questions) Tengo una pregunta… Sí, Juan habla mucho con el profesor en clase. No, Juan no habla mucho en clase. s vo s vo Forming.
La pregunta: Marquen los países con una flecha Saquen el paquete de los mapas.
Formal Commands! Telling people what to do…… You speak, or you are speaking……Hablas, estás hablando This is different from telling (commanding) someone.
TOPICS: SABER/CONOCER AND YO-GO VERBS Essential questions: How do I say whom and what I know? How do I use some other irregular verbs?
Octubre 7, Español 2: Cap. 2B pag. 110 Q: ¿Cuántos estudiantes hay en el salón de clases? ¿Dónde están? “Hay” means there is/ there are.
Spanish Sentence Structure How can we make better sentences?
El futuro What is the future tense? When would you use it?
JUEVES, EL 10 DE SEPTIEMBRE LT: I WILL RECOGNIZE SOME NEW VOCABULARY WORDS. Go over tests & retake procedures Interpretive Assessment: numbers & alphabet.
Essential ?: How do I use these irregular verbs? How are they different than the verbs I already know?
Overclipping It’s very important as a trader that you understand your clip size and what positions this allows you to have. In addition it will help you.
Survival Spanish for travelers Lesson 4: Verbs, verbs everywhere! Part 1.
How would you spell the following word out loud in Spanish? Abuelito.
ECOM-6030 PASOS PARA LA INSTALACIÓN DE EASYPHP Prof. Nelliud D. Torres © - Derechos Reservados.
What time is it? DLT: I can tell time in Spanish..
Un juego de adivinanzas: ¿Dónde está el tesoro? A1B1C1D1E1F1 A4B4C4D4E4F4 A2B2C2D2E2F2 A5B5C5D5E5F5 A3B3C3D3E3F3 A6B6C6D6E6F6 Inténtalo de nuevo Inténtalo.
Essential question: How do I say what I like and what interests/bores me?
LOS VERBOS REFLEXIVOS. WRITE: What is a reflexive verb? A reflexive verb describes when a person doing an action is also receiving the action.
English Language II (2). English Language I (2) Warm-up.
Los verbos reflexivos Objective: To be able to talk about your daily routine. Getting ready for a special event.
100 Book Challenge Desafío de leer 100 libros. Cada niño tendrán: Una bolsa de libros Una carpeta 2 libros para leer cada noche Un informe de lectura.
The imperfect tense. Look at the following 3 sentences. We ate at two every day The hotel was very big I used to live with my grandparents What do they.
Escribir *You can get creative. You can write in the first person which means you are the character, you can use the third person which means you are talking.
Español 2 20 de septiembre de La campana Hoy es martes el 20 de septiembre de 2016 ¿Qué llevan los animales? Los gansos El perro El gato El lagarto.
Tienes un nuevo mensaje…. Ella era una chica timida, llamada Lina, no tenia amigosy solo convivia con su familia especialmente con su madre y su padre…
Go to cessarsc9.wixsite.com/clasedeespanol Click in this icon to see the presentation.
UNIVERSIDAD AUTÓNOMA DEL ESTADO DE HIDALGO ESCUELA SUPERIOR DE ZIMAPÁN
To be, or not to be? Let’s start out with one of the most important verbs in Spanish: ser, which means “to be.”
Hoy es jueves el 8 de diciembre
To be, or not to be? Let’s start out with one of the most important verbs in Spanish: ser, which means “to be.”
Gustar V. Encantar.
Notes: La Hora (Time) How do I tell time in Spanish?
Español 1 11 de mayo de 2017 Good morning, thank you for taking my classes today. For the most part the kids are really great. Here is my schedule for.
Interactive Math Notebooks
First Grade Dual High Frequency Words
Youden Analysis. Introduction to W. J. Youden Components of the Youden Graph Calculations Getting the “Circle” What to do with the results.
Los números.
Quasimodo: Tienes que hacer parte D de la tarea..
Apuntes: La hora Lección 1: Hola, ¿Qué tal?.
Bellringer 10/29 Put this in your NOTES!!! Using questions that you know in Spanish, figure out what the following question words mean. If you can’t.
JKSimMet Software (windows & buttons) Split Engineering Chile Ltda. General Salvo #331 oficina 201 Casilla Sucursal Panorámico Providencia – Santiago,
Directions (The directions are based on the fact that you would delete this slide before you save it to the student directory. Therefore slide 2 will become.
Gustar, Interesar, Aburrir
Development of the concert programme
Quasimodo: How could you express the following information in Spanish (you know 2 ways right now): The test will be on Friday. El examen va a ser el viernes.
Using Adjectives as Nouns
Welcome to PowerPoint gdskcgdskfcbskjc. Designer helps you get your point across PowerPoint Designer suggests professional designs for your presentation,
Regular –ar (present tense)
The causative is a common structure in English. It is used when one thing or person causes another thing or person to do something.
Las Preguntas (the questions) Tengo una pregunta… Sí, Juan habla mucho con el profesor en clase. No, Juan no habla mucho en clase. s vo s vo Forming.
Transcripción de la presentación:

Climate data in R with the raster package Jacob van Etten

Packages There are many packages specifically created for R that allow you to do specialized tasks. One of these packages is raster, created by Robert Hijmans and Jacob van Etten (mainly the former, though). The raster package allows you to work with geographical grid (raster) data.

Get raster in RStudio Click on the “Packages” tab in the lower right corner. Click “Install Packages”. Type “raster” and click on “Install”. Leave “Install dependencies” checked. This will also get some other essential packages.

Load the package With the following command, we load the package into R. Make sure you put this in the first line of your new script. library(raster) help(package="raster") The second function gives you an overview of the functions in the package.

The raster() function The main function to read raster data into R is called (very conveniently) raster. ?raster Let’s make a raster! r1 <- raster() r1 As you can see, there are no values in the raster. Next thing to solve.

Adding values How many values do we need to fill the raster? The function ncell() will tell us. n <- ncell(r1) Let’s make a vector with n random values between 0 and 1 with the function runif(). vals<- runif(n) And we add the values to the raster. values(r1) <- vals

Raster graphics We make a picture of the raster we just made. plot(r1, main=“My first raster map in R”) Now let’s take a look at the different options that plot() gives. ?plot Click “Plot a Raster* object”. Also, take a look at the examples and try some if you want.

Real data Let’s get some real data to play with. This is a raster representing current conditions (a bit over 1 MB). Unzip the file, and put it in a (new) folder. Now make this folder your working directory in R. setwd(“D:/yourfolder”)

Getting raster data into R Reading this data into R is really easy now. r2 <- raster(“current_bio_1_1.asc”) What class is this raster? class(r2) Plot this raster.

Cutting an area of interest The function extents requires a vector of 4 values: {xmin, xmax, ymin, ymax}. For instance: newExtent <- extent(c(60, 100, 0, 40)) Or choose your own area of interest, for instance using Google Earth. Then cut the new extent out of r2 and visualize. r3 <- crop(r2, newExtent) plot(r3)

Raster algebra It is very convenient to calculate with rasters. Try this and visualize the result. r4 <- r3 + sqrt(r3) What happens when you do the following and why? r5 <- r2 + r3

Some operations Aggregating cells means the grid becomes coarser. By default the function aggregate() will take the mean of the cells it will aggregate. r6 <- aggregate(r2, fact=2) Now take a look at the examples under ?aggregate and try to understand what happens.

Interpolation See if you can work this out for yourself. Take a look at the first example of ?interpolate

Sources of data For an overview of a lot of relevant climate and weather data, visit this website:

Moreover... Worldclim data are global climate data (get it using the raster package, getData function) NCDC-NOAA – Global Summary of Day, weather data from thousands of stations (weatherData package) CCAFS data

Worldclim Precipitation at 10 minute resolution wc <- getData(“worldclim”, var=“prec”, res=10) plot(wc)

Global Summary of Day Available from: ftp://ftp.ncdc.noaa.gov/pub/data/gsod/ ftp://ftp.ncdc.noaa.gov/pub/data/gsod/ These data are massive. Use the weatherData package to download these data.