Changeset 9b90bf8 in sasview for src/sas/sasgui/perspectives


Ignore:
Timestamp:
Jul 19, 2017 10:04:45 AM (7 years ago)
Author:
lewis
Branches:
master, ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc, magnetic_scatt, release-4.2.2, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
Children:
a309667
Parents:
d78b5cb
Message:

Use DCT to calculate IDF

Location:
src/sas/sasgui/perspectives/corfunc
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • src/sas/sasgui/perspectives/corfunc/corfunc.py

    r7dda833 r9b90bf8  
    192192            new_plot.xaxis("{x}", 'A') 
    193193            new_plot.yaxis("{g_1}", '') 
    194  
     194            # Linear scale 
    195195            new_plot.xtransform = 'x' 
    196196            new_plot.ytransform = 'y' 
    197197            group_id = GROUP_ID_IDF 
     198            # Show IDF as a curve instead of points 
    198199            new_plot.symbol = GUIFRAME_ID.CURVE_SYMBOL_NUM 
    199200        new_plot.id = label 
  • src/sas/sasgui/perspectives/corfunc/corfunc_panel.py

    rc728295 r9b90bf8  
    277277        self._transformed_data = transforms 
    278278        (transform1, transform3, idf) = transforms 
    279         plot_x = transform1.x[np.where(transform1.x <= 200)] 
    280         plot_y = transform1.y[np.where(transform1.x <= 200)] 
     279        plot_x = transform1.x[transform1.x <= 200] 
     280        plot_y = transform1.y[transform1.x <= 200] 
    281281        self._manager.show_data(Data1D(plot_x, plot_y), TRANSFORM_LABEL1) 
    282282        # No need to shorten gamma3 as it's only calculated up to x=200 
    283283        self._manager.show_data(transform3, TRANSFORM_LABEL3) 
    284         self._manager.show_data(idf, IDF_LABEL) 
     284 
     285        plot_x = idf.x[idf.x <= 200] 
     286        plot_y = idf.y[idf.x <= 200] 
     287        self._manager.show_data(Data1D(plot_x, plot_y), IDF_LABEL) 
    285288 
    286289        # Only enable extract params button if a fourier trans. has been done 
Note: See TracChangeset for help on using the changeset viewer.