Marine isoscapes issues

14 views
Skip to first unread message

Sebastian Giacomino

unread,
Apr 21, 2026, 4:11:21 PMApr 21
to IsoriX
Hello Alexandre,

How are you? Hope everything is good. My name is Sebastian Giacomino. I'm trying to build isoscapes of d13C and d15N from zooplankton samples to find origin of isotopes composition of these in dolphin species living at the Golfo Nuevo and Golfo San José, Chubut, Argentina. For now I'm having 2 issues:

1. I can't upload the elevraster with getelev() as mentioned in the bookown, I get an error that it can't be downloaded due to legal issues

2. I 've tried building my own raster from my study area and when I get to the part where 

dataIsoscape <- isoscape(raster = dataElev,
                           isofit = dataFit)

The sea is masked all in black (picture attached). I've tried using the code you gave to another researcher in the group (worldlimit <- as(extent(CountryBorders), "SpatialPolygons")
sp::proj4string(worldlimit) <- raster::crs(CountryBorders)
LandMask <- rgeos::gDifference(worldlimit, OceanMask))

but it didn't work.

Thank your attention.

Kind regards,

Sebastian 
Rplot.tiff

Alexandre Courtiol

unread,
Apr 21, 2026, 4:49:52 PMApr 21
to IsoriX
Hi Sebastien,

I had a quick look...

- The fact that getelev() does not work is caused by a old bug in terra that has resurfaced: https://github.com/rspatial/terra/issues/2013
It should be solved very soon since the developer from this widely used package is usually very reactive and helpful.

- The code you show is based on old code, IsoriX no longer use the package sp, but terra, so it can be the reason that "it" does not work, but without seeing a full example it is difficult for me to see where the problem may be coming from.

Below is a simple example of how to create a LandMask using IsoriX.
I hope it will sort you out.
++
Alex


library("IsoriX")

## Creating a LandMask
worldlimit <- vect(ext(CountryBorders))
crs(worldlimit) <- crs(CountryBorders)
LandMask <- worldlimit - OceanMask

## Using a silly isoscape on land from the documentation ?isoscape
GNIPDataDEagg <- prepsources(data = GNIPDataDE)
GermanFit <- isofit(
    data = GNIPDataDEagg,
    mean_model_fix = list(elev = TRUE, lat_abs = TRUE)
)
GermanScape <- isoscape(raster = ElevRasterDE, isofit = GermanFit)

## Plot masking the lands
plot(GermanScape, mask = list(mask = LandMask))

Alexandre Courtiol

unread,
Apr 22, 2026, 1:56:41 AMApr 22
to IsoriX
Quick follow up:
getelev() now works again, but one has to install the new version of terra for this:

install.packages("remotes") # you can skip if remotes is already installed
remotes::install_github("rspatial/terra")

++

Sebastian Giacomino

unread,
Apr 24, 2026, 2:40:32 AMApr 24
to IsoriX
Alex,

Thank you much for your advice and the recommendations you gave me regarding both matter. I managed to solve both problems. For future people that might have the same issues:
1- The problem with getelev() was because I had to installed Rtools and update the R console as you told me, besides the lines of code you gave
2- The LandMask code worked perfectly with my isoscape

Again thank you so much and you'll be hearing from me if I need some more help.

kind regards,
Sebastian

Reply all
Reply to author
Forward
0 new messages