From 835a1c550069db7a5bcbdaf256525054bb99e7c6 Mon Sep 17 00:00:00 2001 From: Sam Green Date: Thu, 11 Jul 2024 16:39:36 +1000 Subject: [PATCH] Typo in topsoil calc --- src/mopper/calculations.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mopper/calculations.py b/src/mopper/calculations.py index 1adf216..8ce6783 100644 --- a/src/mopper/calculations.py +++ b/src/mopper/calculations.py @@ -1175,7 +1175,7 @@ def calc_topsoil(soilvar): # calculate the fraction of maxlev which falls in first 10cm fraction = (0.1 - depth[maxlev -1])/(depth[maxlev] - depth[maxlev-1]) topsoil = soilvar.isel(depth=slice(0,maxlev)).sum(dim='depth') - topsoil = topsoil + fraction * topsoil.isel(depth=maxlev) + topsoil = topsoil + fraction * soilvar.isel(depth=maxlev) return topsoil #----------------------------------------------------------------------