{"id":191,"date":"2009-02-08T06:28:03","date_gmt":"2009-02-08T06:28:03","guid":{"rendered":"http:\/\/ahay.org\/blog\/?p=191"},"modified":"2015-08-04T23:51:40","modified_gmt":"2015-08-04T23:51:40","slug":"what-are-the-most-popular-programs-in-madagascar","status":"publish","type":"post","link":"https:\/\/ahay.org\/blog\/2009\/02\/08\/what-are-the-most-popular-programs-in-madagascar\/","title":{"rendered":"What are the most popular programs in Madagascar?"},"content":{"rendered":"<p>In reverse order, the 10 most popular programs in <tt>Madagascar<\/tt> are:<br \/>\n<strong>10.<\/strong> <a href=\"\/RSF\/sftransp.html\">sftransp<\/a> Transpose two axes in a dataset (<em>used in 83 projects<\/em>)<br \/>\n<strong>9.<\/strong> <a href=\"\/RSF\/sfadd.html\">sfadd<\/a> Add, multiply, or divide RSF datasets (<em>used in 92 projects<\/em>)<br \/>\n<strong>8.<\/strong> <a href=\"\/RSF\/sfgraph.html\">sfgraph<\/a> Graph plot (<em>used in 99 projects<\/em>)<br \/>\n<strong>7.<\/strong> <a href=\"\/RSF\/sfspike.html\">sfspike<\/a> Generate simple data: spikes, boxes, planes, constants (<em>used in 109 projects<\/em>)<br \/>\n<strong>6.<\/strong> <a href=\"\/RSF\/sfcat.html\">sfcat<\/a> Concatenate datasets (<em>used in 110 projects<\/em>)<br \/>\n<strong>5.<\/strong> <a href=\"\/RSF\/sfput.html\">sfput<\/a> Input parameters into a header (<em>used in 118 projects<\/em>)<br \/>\n<strong>4.<\/strong> <a href=\"\/RSF\/sfmath.html\">sfmath<\/a> Mathematical operations on data files (<em>used in 143 projects<\/em>)<br \/>\n<strong>3.<\/strong> <a href=\"\/RSF\/sfdd.html\">sfdd<\/a> Convert between different formats (<em>used in 163 projects<\/em>)<br \/>\n<strong>2.<\/strong> <a href=\"\/RSF\/sfwindow.html\">sfwindow<\/a> Window a portion of a dataset (<em>used in 216 projects<\/em>)<br \/>\n<strong>1.<\/strong> <a href=\"\/RSF\/sfgrey.html\">sfgrey<\/a> Generate raster plot (<em>used in 260 projects<\/em>)<br \/>\nMore documentation on these and other programs &#8211; in <a href=\"\/wiki\/Guide_to_madagascar_programs\">Guide to Madagascar programs<\/a>.<br \/>\nThe three most popular programs in the &#8220;generic&#8221; category (signal processing programs applicable to any kind of data) are <a href=\"\/RSF\/sffft1.html\">sffft1<\/a> (Fast Fourier Transform along the first axis), <a href=\"\/RSF\/sfnoise.html\">sfnoise<\/a> (Add random noise to the data), and <a href=\"\/RSF\/sfsmooth.html\">sfsmooth<\/a> (Multi-dimensional triangle smoothing).<br \/>\nThe three most popular programs in the &#8220;seismic&#8221; category (signal processing programs applicable to seismic data) are <a href=\"\/RSF\/sfmutter.html\">sfmutter<\/a> (Muting), <a href=\"\/RSF\/sfricker1.html\">sfricker1<\/a> (Convolution with a Ricker wavelet), and <a href=\"\/RSF\/sfsegyread.html\">sfsegyread<\/a> (Convert a SEG-Y or SU dataset to RSF).<br \/>\nHere is a simple Python script that extracts the popularity information:<div class=\"code-box\"><div class=\"code-title\"><i class=\"fa fa-code\"><\/i> <div class=\"pull-right\"><a href=\"#\" class=\"btn btn-default btn-xs toggle-code\" data-toggle=\"tooltip\" title=\"Toggle code\"><i class=\"fa fa-toggle-up\"><\/i><\/a><\/div><\/div><pre ><I><FONT COLOR=\"#B22222\">#!\/usr\/bin\/env python<BR><\/FONT><\/I><B><FONT COLOR=\"#A020F0\">from<\/FONT><\/B> rsfdoc <B><FONT COLOR=\"#A020F0\">import<\/FONT><\/B> progs<BR><B><FONT COLOR=\"#A020F0\">import<\/FONT><\/B> rsfprog<br \/>\n<B><FONT COLOR=\"#A020F0\">def<\/FONT><\/B> <B><FONT COLOR=\"#0000FF\">nuses<\/FONT><\/B>(p):<BR>    <B><FONT COLOR=\"#BC8F8F\">&#8216;how many times a program is used&#8217;<\/FONT><\/B><BR>    n=0<BR>    uses = progs[p].uses<BR>    <B><FONT COLOR=\"#A020F0\">for<\/FONT><\/B> book <B><FONT COLOR=\"#A020F0\">in<\/FONT><\/B> uses.keys():<BR>        <B><FONT COLOR=\"#A020F0\">for<\/FONT><\/B> chapter <B><FONT COLOR=\"#A020F0\">in<\/FONT><\/B> uses[book].keys():<BR>            n = n + len(uses[book][chapter])<BR>    <B><FONT COLOR=\"#A020F0\">return<\/FONT><\/B> n<br \/>\nprograms = progs.keys()<BR>programs.sort(<B><FONT COLOR=\"#A020F0\">lambda<\/FONT><\/B> x,y: nuses(y)-nuses(x))<br \/>\n<B><FONT COLOR=\"#A020F0\">for<\/FONT><\/B> prog <B><FONT COLOR=\"#A020F0\">in<\/FONT><\/B> programs:<BR>    <B><FONT COLOR=\"#A020F0\">print<\/FONT><\/B> <B><FONT COLOR=\"#BC8F8F\">&#8216;%s is used in %d projects&#8217;<\/FONT><\/B> % (prog,nuses(prog))<br \/>\n<\/PRE><\/p>\n","protected":false},"excerpt":{"rendered":"<p>In reverse order, the 10 most popular programs in Madagascar are: 10. sftransp Transpose two axes in a dataset (used in 83 projects) 9. sfadd Add, multiply, or divide RSF datasets (used in 92 projects) 8. sfgraph Graph plot (used in 99 projects) 7. sfspike Generate simple data: spikes, boxes, planes, constants (used in 109 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_import_markdown_pro_load_document_selector":0,"_import_markdown_pro_submit_text_textarea":"","activitypub_content_warning":"","activitypub_content_visibility":"local","activitypub_max_image_attachments":4,"activitypub_interaction_policy_quote":"","footnotes":""},"categories":[4],"tags":[],"class_list":["post-191","post","type-post","status-publish","format-standard","hentry","category-faq"],"_links":{"self":[{"href":"https:\/\/ahay.org\/blog\/wp-json\/wp\/v2\/posts\/191","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ahay.org\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ahay.org\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ahay.org\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/ahay.org\/blog\/wp-json\/wp\/v2\/comments?post=191"}],"version-history":[{"count":1,"href":"https:\/\/ahay.org\/blog\/wp-json\/wp\/v2\/posts\/191\/revisions"}],"predecessor-version":[{"id":724,"href":"https:\/\/ahay.org\/blog\/wp-json\/wp\/v2\/posts\/191\/revisions\/724"}],"wp:attachment":[{"href":"https:\/\/ahay.org\/blog\/wp-json\/wp\/v2\/media?parent=191"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ahay.org\/blog\/wp-json\/wp\/v2\/categories?post=191"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ahay.org\/blog\/wp-json\/wp\/v2\/tags?post=191"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}