Batch Changes
Related blog post: Where in the World Is My Well?
Sometimes you have a number of LAS files that all need the same change. For example, they might all be missing the same mnemonic, or perhaps the value of a mnemonic is not spelled consistently or correctly. In LAS Explorer you can now perform batch changes easily, to all files in a folder, or selected files, as needed. There is also some special support for working with latitude and longitude values.
Let's use for an example a batch of files for wells from Alberta, Canada. This is a publicly available dataset on the Canada Open Government website. This particular batch contains 8,763 files. That's a lot of files - it would be very time-consuming to make the same change to these files one at a time!
When we open the folder containing the files, the first thing that stands out is that for some reason CTRY is blank for almost all the files, and in many of the files, STAT is set to "Canada". Note: a few of these files have non-Canadian location values for some mnemonics, though their latitude and longitude values place them in Canada, and the entire dataset comes from Canada. For purposes of this blog post, we'll just assume all of these wells are in fact in Alberta, Canada.
Let's fix that. First, we need to select all LAS files in the folder. We can do that with Ctrl + A or from the context menu for the folder (right-click on the folder row). Then, on any selected file, right-click over the CTRY column, and select "Set value for CTRY in selected files..." from the context menu. Let's set CTRY to "Canada".
Then let's repeat this operation for the STAT column, we want to clear the STAT value, so we'll just leave that blank.
Before we make these changes, let's check something else. Do these files have latitude and longitude values? Well, they do, but they all use a pair of mnemonics that is not common to designate those values.
Here's what the data looks like when we add columns for those two mnemonics:
We now notice something else: the longitude values are all positive, when they should be negative. We'll deal with that later. First, let's change the mnemonics to something more standard.
Note that all we've done so far is to specify what changes we would like to make to these files. Now let's actually apply the changes.
When we click on 'Apply', we get a confirmation dialog with a list of all the changes to be applied.
Here are the results.
We noticed earlier that the longitude values are incorrect for wells in Canada. LAS Explorer can validate latitude and longitude, let's open one of the files, then from the Geo menu, select Latitude/Longitude.
The description for the longitude value says that it is "Longitude west of Greenwich", which is true, strictly speaking, but this value should be negative to indicate that to software, or it will be interpreted as east of Greenwich (in this case, somewhere in Russia). There's a nice validation here in LAS Explorer that detects that this value is not consistent with the CTRY value of Canada.
Back in the explorer interface, let's right-click on the folder row and select "Latitude and longitude..." from the context menu. This will bring up a dialog box with all the detected latitude and longitude pairs for all LAS files in the folder.
Here it's easy to set all latitude values north or south, or all longitude as east or west. We will click on the "Longitude" button, then select "Make west (degrees are negative)". The longitude values are now all negative. We can now save our changes.
Let's do a spot check on one file. The warning about Canada should be gone, and it is.
In that same dialog where we corrected the longitude values, we can also export all of the extracted geographical coordinate pairs to a Keyhole Markup Language (KML) file, which can be then be imported into most GIS programs, including Google Earth. 8763 closely spaced wells will be overwhelming to look at in Google Earth, but let's see what it will look like if we select a few, generate the KML file, and open that file in Google Earth.
If you would like to see more batch change capabilities, let us know, we’d like to hear about it.
Back to blog index