Skip to content
This repository has been archived by the owner on Jun 13, 2023. It is now read-only.

problem in EBS UTM conversion? #18

Open
DanOvando opened this issue Aug 1, 2017 · 5 comments
Open

problem in EBS UTM conversion? #18

DanOvando opened this issue Aug 1, 2017 · 5 comments

Comments

@DanOvando
Copy link

Attempting to merge location of estimated knots with other databases, and noticed that the locations produced by Convert_LL_to_UTM_Fn for some regions appear to be off. Specifically, running the VAST--single-species-example.Rmd for the EBSBTS data, calling Convert_LL_to_UTM_Fn and by extension PBSmapping::convUL results in convUL guessing that the data are in UTM zone 32, which runs over central Africa.

Setting flip_around_dateline to FALSE in Prepare_EBS_Extrapolation_Data_Fn.r seems to solve the problem, as convUL now assigns a mean UTM zone of 2, and the eastings and northings now look more or less right, though they still don't perfectly match values produced by conversion from lat/lons by rgdal::project. Any thoughts? Bug in flip_around_dateline conversion? Or am I just missing something?

@James-Thorson
Copy link
Contributor

I don't know anything about rgdal::project, maybe that deals more naturally with dateline projection issues?

But yes, Extrapolation_List keeps track of the UTM-zone and whether it was flipped around the dateline, and then this is used in other functions to that it is consistent internally. probably a better way to do this ;)

@DanOvando
Copy link
Author

Ah, so this is a hack to deal with the dateline in other spots in the code? i.e. if other functions see flip_round_dateline = T and zone = 32, they convert that spot to a place in the EBS, even though if you technically try and map those eastings and northings directly you'll get a spot off the west coast of Africa?

@James-Thorson
Copy link
Contributor

correct.

@DanOvando
Copy link
Author

got it, thanks! I may submit some changes to track the "true" lat-long of the knots as well just for clarity if you want

@James-Thorson
Copy link
Contributor

James-Thorson commented Aug 1, 2017 via email

@DanOvando DanOvando reopened this Aug 2, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants