search for: asort

Displaying 6 results from an estimated 6 matches for "asort".

Did you mean: abort
2011 Jan 21
4
clustering fuzzy
hello, i'm pete ,how can i order rows of matrix by max to min value? I have a matrix of membership degrees, with 82 (i) rows and K coloumns, K are clusters. I need first and second largest elements of the i-th row. for example 1 0.66 0.04 0.01 0.30 2 0.02 0.89 0.09 0.00 3 0.06 0.92 0.01 0.01 4 0.07 0.71 0.21 0.01 5 0.10 0.85 0.04 0.01 6 0.91 0.04 0.02 0.02 7 0.00 0.01 0.98 0.00 8 0.02
2011 Jan 31
0
silhouette fuzzy
...04 0.01 2 0.89 0.09 0.02 0.00 3 0.92 0.06 0.01 0.01 4 0.71 0.21 0.07 0.01 5 0.85 0.10 0.04 0.01 6 0.91 0.04 0.02 0.02 > head(t(A.sort)) [,1] [,2] [,3] [,4] 1 0.66 0.30 0.04 0.01 2 0.89 0.09 0.02 0.00 3 0.92 0.06 0.01 0.01 4 0.71 0.21 0.07 0.01 5 0.85 0.10 0.04 0.01 6 0.91 0.04 0.02 0.02 > H.Asort=head(t(A.sort)) > H.Asort[,1]-H.Asort[,2] 1 2 3 4 5 6 0.36 0.80 0.86 0.50 0.75 0.87 > H.Asort=t(H.Asort[,1]-H.Asort[,2]) This is the differences vector by multiplying trasformed table ris$silinfo. > ris$silinfo $widths cluster neighbor sil_width 72 1...
2006 Jun 09
1
Idempotent apply
Dear all, I have been working on an idempotent version of apply, such that applying a function f(x) = x (ie. force) returns the same array (or a permutation of it depending on the order of the margins): a <- array(1:27, c(2,3,4)) all.equal(a, iapply(a, 1, force)) all.equal(a, iapply(a, 1:2, force)) all.equal(a, iapply(a, 1:3, force)) all.equal(aperm(a, c(2,1,3)), iapply(a, 2, force))
2007 Oct 03
1
Reimplement order somehow
...231 11 12 0 1 order(n) [1] 15 1 16 2 3 4 5 6 7 8 9 10 13 14 12 11 PHP <?php $string = "1 2 3 4 5 6 7 8 9 10 300 231 11 12 0 1"; $array = explode(" ", $string); foreach ($array as $key => $value) { $array_new[$key + 1] = $value; } $array = $array_new; asort($array); foreach ($array as $key => $value) { print " $key"; } ?> output from php is: 15 1 16 2 3 4 5 6 7 8 9 10 13 14 12 1 (same as from the R script), now I use another numbers: 0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10...
2006 Apr 08
0
Typo and Instant Rails 1.2
...e changes, themselves, do appear in the actual blog. When the *Sort Alphabetically* is clicked under categories an error occurrred. I changed the code as follows: C:\InstantRails-1.2\rails_apps\typo1000\app\controllers\admin\categories_controller.rb <typo:code lang="ruby"> def asort Category.reorder_alpha #render_component :action => "category_container" - Removed and added two lines below - Ed Gard @categories = Category.find(:all, :order => :position) render :partial => "categories" end </typo:code> Other that that, Typo ap...
2008 Feb 15
1
Sortable limit number of elements
Hello, Well, i need to limit the number of elements in a sortable. I new to scriptaculo but i have lots of experiencie with javascript. Since limit the number of elements is not supported by Sortable i would like to implement, i already took a look at the Sortable class in dragdrop.js and it looks like that onHover and onEmptyHover deal with the update of the UI, however I''m not unable