spacetelescope/specviz

Cube Operations Fitted Linemap not working?

hcferguson opened this issue · 1 comments

I'm not sure I understand the intended output of fitted linemap, but I'm not getting what I expected.

What I expected to see was the equivalent of simple linemap, but based on a model fit to each spaxel rather than a sum over the pixels within the ROI. So the output would be a 2D image rather than a 3D cube. I'm getting a 3D cube.

If the fit to the line creates a dataset called new_data, and the spectral axis is axis 0, then the fitted linemap would be (new_data*mask).sum(axis=0). What I'm seeing in the source code in viewer.py is that it is just returning new_data.

Ah, you're right. We're missing the summation in this function.