Giter VIP home page Giter VIP logo

Comments (4)

danbgraham avatar danbgraham commented on July 30, 2024

I've added a minor fix to the function which calculates the pitch angle distribution so it should work with fast mode data. This is added to the devel branch.

Some points about the command lines used:
(1) The function e64 recalculates the particle distribution 64 energy channel resolution and half the time resolution. It will only work when there are two energy tables used. This means it will only work for burst mode data in the early phase of the mission. It will not work for fast mode data and in general is not needed for most analyses.
(2) When calculating the pitch angle the B field must be in the same coordinate system as the particle distribution function (dmpa coordinates for B).

E.g.,
ic = 1;
Tint = irf.tint('2017-06-17T20:20:00.00Z/2017-06-17T20:30:00.00Z');
c_eval('ePDist = mms.get_data(''PDe_fpi_fast_l2'',Tint,?);',ic);
c_eval('Bxyz=mms.get_data(''B_dmpa_fgm_srvy_l2'',Tint,?);',ic);
ePDistpitch = ePDist.pitchangles(Bxyz,24).deflux;
irf_spectrogram(ePDistpitch.specrec('pitchangle'))

from irfu-matlab.

zhang-chi-IGGCAS avatar zhang-chi-IGGCAS commented on July 30, 2024

Thanks a lot, it is very helpful for me. this command line
"ePDistpitch = ePDist.pitchangles(Bxyz,24).deflux;" can work very well, and we can get the variable which is named as "ePDistpitch";
However, when i want to plot, such a mistake has occurred. I used this command line:

eint1 = [3e1 3e2];
irf_spectrogram(h,ePDistpitch.elim(eint1).specrec('pa'),'log','donotfitcolorbarlabel');

Then matlab shows that"
wrong use ismember>ismemberR2012a (line 212)
wrong ismember (line 148)
[lia,locb] = ismemberR2012a(A,B,logical(flaginds(1)));
wrong PDist/elim (line 2229)
[esteptable,~] =
ismember(energy,PD.ancillary.energy1,'rows');
wrong PDist/subsref (line 123)
[varargout{1:nargout}] = builtin('subsref',obj,idx);

I think that it is due to the "ePDist.ancillary" is empty, so could you help me to solve it?

Actually, I just want to plot the ion pitch angel distribution during about 1 hour interval, so I have to use fast-mode data. Could you show me a example about how to do it ?

from irfu-matlab.

danbgraham avatar danbgraham commented on July 30, 2024

We've made a revision that should correct this now. Please try again with the latest version.

Regarding, an example of plotting fast mode data, you can use the latest version of Example_MMS_particle_PAD.m. For the initial loading of variables you can replace brst with fast (for FPI and EDP products) and brst with srvy (for FGM products). The analyses and plotting should now work fine with both fast and brst data.

from irfu-matlab.

zhang-chi-IGGCAS avatar zhang-chi-IGGCAS commented on July 30, 2024

Thanks a lot ,it can work well now.

from irfu-matlab.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.