Skip to content

addition of repetitive weights check & bug fixes

Check for stations x species combinations where all weights are equal but not zero and set them to 0.

I am not entirely sure where to place this piece of code, so please feel free to distribute it where you think it is more appropriate for the app functionality. The function checks if there are stations that a species has weight measurements that are repetitive (more than 1), identical and non-zero. Unless this check is there, there are problems in the pushback to the db part. If there are such cases, the function currently returns a table with these stations. These station-species combos are then used as input to modify the biosequence_df by setting the copy_of_weight to 0 for these cases (as they are worthless for any subsequent analysis including weight). Feel free to modify the function to return only the biosequence_df if you think it is better. The table returned is only for visual reasons in case one wants to see where are the problematic cases. The test is an automatic one and should be carried out for every dataset. Whether we want to have it executed by the user, or automatically carried out and when a survey is loaded and just showing the table output to the user, is your choice, I am good with both.

#Some bug fixes and updated set_weight_intervals function to include cases that were missed previously by the checks (a) when the weight interval was 5g and b) the sum_of_weight was negative problematic behaviour was noticed. This is now fixed.

Merge request reports

Loading