{"action":"closed","issue":{"url":"https://api.github.com/repos/Chandra-MARX/doc/issues/2","labels_url":"https://api.github.com/repos/Chandra-MARX/doc/issues/2/labels{/name}","comments_url":"https://api.github.com/repos/Chandra-MARX/doc/issues/2/comments","events_url":"https://api.github.com/repos/Chandra-MARX/doc/issues/2/events","html_url":"https://github.com/Chandra-MARX/doc/issues/2","id":54619938,"number":2,"title":"Link to Sherpa thread with bug to generate MARX input spectrum","user":{"login":"hamogu","id":498688,"avatar_url":"https://avatars.githubusercontent.com/u/498688?v=3","gravatar_id":"","url":"https://api.github.com/users/hamogu","html_url":"https://github.com/hamogu","followers_url":"https://api.github.com/users/hamogu/followers","following_url":"https://api.github.com/users/hamogu/following{/other_user}","gists_url":"https://api.github.com/users/hamogu/gists{/gist_id}","starred_url":"https://api.github.com/users/hamogu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hamogu/subscriptions","organizations_url":"https://api.github.com/users/hamogu/orgs","repos_url":"https://api.github.com/users/hamogu/repos","events_url":"https://api.github.com/users/hamogu/events{/privacy}","received_events_url":"https://api.github.com/users/hamogu/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/Chandra-MARX/doc/labels/upstream-fix%20required","name":"upstream-fix required","color":"707070"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-01-16T20:15:36Z","updated_at":"2015-05-29T17:05:17Z","closed_at":"2015-05-29T17:05:17Z","body":"The docs link to a Sherpa thread on how to make MARX input spectra with Sherpa, but that thread has an error. The thread in question is: http://cxc.harvard.edu/sherpa/threads/marx/\r\n\r\nIt contains this line of code::\r\n\r\n    sherpa> energy = (get_source_plot(lo=1.0,hi=8.0).xhi+get_source_plot(lo=1.0,hi=8.0).xlo)/2\r\n\r\nand this line of text::\r\n\r\n    The ASCII file written by the above save_arrays command lists the center of the energy bin...\r\n\r\nThose need to be changed. The MARX format for input spectra is\r\n\r\nupper_bin_edge_1  photon_fluxdensity_1\r\nupper_bin_edge_2  photon_fluxdensity_2\r\nupper_bin_edge_3  photon_fluxdensity_3\r\n...\r\n\r\n(In this example, MARX would use two bins [upper_bin_edge_1, upper_bin_edge_2] and [upper_bin_edge_2, upper_bin_edge_3]. \"photon_fluxdensity_1\" can be any number - it is not used.)\r\n\r\n\r\nSo, the following Sherpa code would be correct::\r\n\r\n    sherpa> energy = (get_source_plot(lo=1.0,hi=8.0).xhi\r\n\r\nI can provide a correct example in the MARX docs, but I don't want to duplicate work uselessly.\r\n\r\nThis issue is here so I don't forget to check back if the Sherpa thread gets fixed, or if not, explain it in the MARX docs."}}