 Hello, I'm Stacy. I'm a GIS analyst with a natural capital project, and I'm glad that you've joined me to learn some techniques for working with the geospatial data that is used by the invest ecosystem services modeling tool set. A reminder that the series is not an introduction to GIS in general, nor an introduction to GIS software. Those cover specific topics that are useful for working with the invest models. This episode provides an introduction to working with the biophysical tables. To get the most out of this tutorial, I highly recommend following along in your own GIS session. In this video, we will demonstrate techniques in ArcGIS, and we will be working with some sample data. The research for this video provides a link to the sample data that we'll be using. So if you haven't already, now is a good time to pause this video, download the sample data, unzip it, and bring up an ArcGIS session before continuing. In this episode, we're looking at the biophysical table that most invest models require, and specifically how that table relates to a land use and land cover map. Many invest models use a land use and land cover map, so we will focus on that for this tutorial. The models that don't use land use have an equivalent input such as habitat, which is mapped to a table of parameter values and the same principles apply. Here's a list of just a few of the invest models that have biophysical tables linked to a land use map. There are others as well, like the rest of the freshwater models that aren't listed here. You can see that this list covers a range of services, even blue carbon, and these land use parameters are very important for modeling. So it's important to understand how to create these tables to work well with the spatial data that they are mapped to. Now let's go to our GIS and start by looking at the land use map. If you don't already have the sample data in your GIS session, let's navigate to the sample data folder, which is called biophysical table data ArcGIS. And in here we have a layer LULCESANapol.tif. Bring that into your GIS session. Inside ArcGIS. If we right click on this layer, we can open the attribute table. Now inside the attribute table, we see several columns. The one that is most important for this purpose is the value field. This value field must contain a unique integer code for each land use and land cover class in your map. In this case, we can see that a value of 10 corresponds to rain fed cropland, a value of 11 corresponds to herbaceous cover, and so on. Now the way the model works is to do a table join between this raster and the biophysical table based on the raster's value column. Then it assigns values from the biophysical table to the raster's land use classes so that it can use those values in subsequent modeling calculations. Because of this, every one of these integer values must have an entry in the model's biophysical table or the model will produce an error. So let's see how to create the biophysical table to include everything you need. What I typically do is export the land cover raster's attribute table, then edit it in Excel. There are other ways to do this, but I'm just going to show you one method that I typically use. Now to export the raster attribute table, we can click on the icon in the upper left hand corner and go down to export. The export data window will appear, and at the top, we want to make sure that we are exporting all records. Then we can navigate to where we want to save the table. I'm going to save mine to the same folder where I have this tutorial sample data, which is biophysical table data ArcGIS. It's important to go down and change the type of file this is, and we're going to select text file. And then we're going to type in the name of the table, which I'm going to call biophysical table, Nepal dot CSV. So I'm going to call this biophysical table Nepal dot CSV. Note that I am giving the file a dot CSV extension. This stands for comma separated value, and it is a type of table that is supported by many spreadsheet programs, and it is the table format that is used by invest. Right now we can click save. And then we click OK. It will save the table for us. And when it asks if you want to add the new table to your map. You could say no. Because personally, I find it much easier to edit tables in Excel rather than within ArcGIS. So we will open this table in Excel next. Now you may use a different spreadsheet program instead. That's totally fine. We won't be doing anything complicated, and it should be easy to follow along. Now back to our operating system window. We should see our biophysical table CSV. And let's open it up in your spreadsheet program. We can see that this table contains all of the columns from this, the raster, most importantly, including this value column. In order to use this table in an invest model, we must make sure that this table has all of the columns that are required for the model. The invest user guide describes the requirements for each model. So let's do an example using the sediment or SDR model and open its user guide page. In this video's web page, you'll see a link that goes directly to the SDR data needs section of the user guide, and you can click on that link. The most chapter of the user guide has a data needs section, and this describes all of the inputs for the model, what formats required and their units, as well as any special formatting or naming conventions. When using a new model, it is totally critical to consult the data needs section in order to understand what is required. We also provide sample data for each model, and that gives you an example and a template from formatting your own data. And I highly recommend also checking out the sample data when you're learning a new model. In this data needs section. First, let's look at the land use and land cover entry. The land use and land cover entry emphasizes that all values in this raster must have corresponding entries in the biophysical table. So let's see what's required in the biophysical table for SDR. The biophysical table entry says that this is a dot CSV table, and it again emphasizes that all ulc classes in the ulc raster must have corresponding values in this table. Now each row in the table corresponds to one land cover class. And there are three required columns that are listed here. And this one is LU code. Okay, this is the column that contains all of the unique integer land cover classes that are in your land cover raster. So these will correspond to the value column in the raster. The other two required columns are us lec and us lep. And both of these are floating point values between zero and one. So if you're trying into any detail about the SDR model itself. These are sediment related factors that are assigned to each land cover class. Each invest model will have its own specific parameters that are required. These are just for SDR. So now that we know that the table must have three columns, and they must be named LU code, us lec and us lep. The table may have additional columns and invest will just ignore them. So let's go back to our table in Excel. Since the value column corresponds to the LU code column for invest, we can simply change the name of this column from value to LU code. So let's do that. Now, we must add two new columns us lec and us lep. In order for the model to run successfully, every row in the table must have a valid value for both us lec and us lep. Okay, right now we're not concerned about the values themselves, just formatting the table. So we're going to make a column called us le underscore C, and another one us le underscore P. The user guide said the values must be floating point between zero and one. For now, let's just do an easy thing of assigning a value of 0.5 to all of the land cover classes for us lec. And we'll assign a value of one to all of the land cover classes for us lep. So now we see that every one of these land cover classes, every one of these rows has a value for both us lec and us lep. And I'll emphasize that these values are not what you would use in an actual analysis. This is only for the purposes of this tutorial. When you're doing your own analysis, you will be doing a literature search to find the best value for each individual land cover class in your study area. And this can be a very time consuming process, but it is important, since the models are typically quite sensitive to the parameters in the bio physical table. Right, but these are just bogus values that we'll use for now. Now we need to save this table with our edits. And to do this will go on to file and then save as now up here, we will see the type of file by default on my screen. It is listed as CSV comma delineated. And this is correct. This is the type of file that we want to use. And if we click on the drop down, you'll see that there are other CSV types, but I do not recommend using them. Right, because some of them can cause an error in invest. The one that I recommend that you use is CSV comma delineated. And if your screen is like mine, that will be there by default. Now we can click the save button. The table we just created should work fine and invest, but what if it doesn't. It's very common to get errors that are related to the bio physical table. So let's look at some of them and how to troubleshoot them. The most common errors happen because there are integer values in the land cover raster that are not included in the bio physical table. The model will determine this while it's running, and you will get an error message like you see here. Now this error is very helpful in telling you what went wrong. In this example, invest found that the values 1020 and 40 are present in the land cover raster, but they are not present in the bio physical table. With an error like this, you'll need to go back and edit your bio physical table to add entries for values 1020 and 40, and then try running the model again. Now if your bio physical table is missing a required field, like L you code or us LEP invest will give you an error when you enter the table into the user interface. If this happens, you will see red X's next to the bio physical table, as well as in the run button like you see here. And when you click on the red X, there is a message telling you which required field is missing. If this happens, you'll need to edit the bio physical table to add this field and populate it with values for every land cover class, and then try running the model again. Okay, that's enough for this session. You might want to save your ArcGIS session so you can keep using it for later episodes. If you have any questions or comments about this episode, we'd love to hear from you on our community forum. There's a link to the forum in this video's webpage, where you can search for previous posts and create a new post under the category of training. Thanks for watching Techies at NatCap. We'll see your posts and we will respond as soon as we can. Thanks for following along.