elasticsearch-ruby
https://github.com/elastic/elasticsearch-ruby
Ruby
Ruby integrations for Elasticsearch
Matrix#find_index
:call-seq:
index(value, selector = :all) -> [row, column]
index(selector = :all){ block } -> [row, column]
index(selector = :all) -> an_enumerator
The index method is specialized to return the index as [row, column]
It also accepts an optional +selector+ argument, see #each for details.
Matrix[ [1,2], [3,4] ].index(&:even?) # => [0, 1]
Matrix[ [1,1], [1,1] ].index(1, :strict_lower) # => [1, 0]Edit
git clone [email protected]:elastic/elasticsearch-ruby.git
cd elasticsearch-ruby
open
Contribute
# Make a new branchgit checkout -b -your-name--update-docs-Matrix-find_index-for-pr
# Commit to gitgit add git commit -m "better docs for Matrix#find_index"
# Open pull requestgem install hub # on a mac you can `brew install hub`
hub fork
git push <your name> -your-name--update-docs-Matrix-find_index-for-pr
hub pull-request
# Celebrate!