Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

request: support averaging in fits2fits, not just binning #40

Closed
o-smirnov opened this issue Jul 9, 2018 · 2 comments
Closed

request: support averaging in fits2fits, not just binning #40

o-smirnov opened this issue Jul 9, 2018 · 2 comments

Comments

@o-smirnov
Copy link
Contributor

I've realized the "bin" option in fits2fits actually performs as advertised, i.e. sums the pixels in a bin. Would it be possible to add an option to take the mean value instead of a sum?

We usually deal with flux density images, so summing breaks our units...

@ericmandel
Copy link
Owner

Yes, I can do that (not in one day, though) ... must be nice to have so many photons that you need to take the mean (not the X-ray experience!)

@ericmandel
Copy link
Owner

JS9 now supports averaging the pixels as well as summing them when binning. You can:

  1. set JS9.globalOpts.binMode to "a" (averaging) or "s" (summing) in your js9prefs.js file to change the global default.

  2. use the Preferences plugin to change the value on the fly for that session.

  3. append an "a" to the bin value in the Binning plugin to set "averaging" on the fly for that section.

  4. JS9.Preload("foo.fits", {bin: "4a"}) to load a binned file using averaging.

It's all updated in GitHub. Lots of changes to offer all of the above options, so let me know if you find a problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants