# \#match

**URL:** https://discourse.julialang.org/tag/match/33.md

[Latest](https://discourse.julialang.org/latest.md) · [Categories](https://discourse.julialang.org/categories.md) · [Tags](https://discourse.julialang.org/tags.md)

---

## [Pattern matching in Matrix](https://discourse.julialang.org/t/pattern-matching-in-matrix/123831)

<div class="topic-metadata">

**Author:** [@Lincoln\_Hannah](https://discourse.julialang.org/u/Lincoln_Hannah)\
**Replies:** 3\
**Last updated:** [December 16, 2024, 8:34am UTC](https://discourse.julialang.org/t/pattern-matching-in-matrix/123831 "2024-12-16T08:34:11Z")

</div>

Find each instance of the smaller matrix in the larger and create a NamedTuple (;a,b) \[ :X a \_ b \_ :Y \] \[ 1 2 3 :X 1 2 3 4 :Y :X 1 2 4 5 :Y 10 11 12 :X …

---

## [Matching for interpolation](https://discourse.julialang.org/t/matching-for-interpolation/103636)

<div class="topic-metadata">

**Author:** [@Lincoln\_Hannah](https://discourse.julialang.org/u/Lincoln_Hannah)\
**Replies:** 4\
**Last updated:** [September 8, 2023, 2:49pm UTC](https://discourse.julialang.org/t/matching-for-interpolation/103636 "2023-09-08T14:49:24Z")

</div>

Is there a matching package that can do something like V = \[1.1, 2, 4.8, 6, 9, 11\] x = 5.1 @match begin V\[i\] ≤ x \< V\[i+1\] =\> #some interp function of V\[i\] and V\[i+i\]

---

## [Type Nothing has no field match](https://discourse.julialang.org/t/type-nothing-has-no-field-match/95904)

<div class="topic-metadata">

**Author:** [@hungpham3112](https://discourse.julialang.org/u/hungpham3112)\
**Replies:** 1\
**Last updated:** [March 11, 2023, 5:57am UTC](https://discourse.julialang.org/t/type-nothing-has-no-field-match/95904 "2023-03-11T05:57:27Z")

</div>

I’m learning Linear Regression model with housing dataset from Kaggle. Dealing with a problem to extract int or float from string make me some confusing. # rename columns renamed\_df = rename(df2, Dict("Diện tích" =\> "A…

---

## [@match alternative catchall](https://discourse.julialang.org/t/match-alternative-catchall/89426)

<div class="topic-metadata">

**Author:** [@Lincoln\_Hannah](https://discourse.julialang.org/u/Lincoln_Hannah)\
**Replies:** 4\
**Last updated:** [October 31, 2022, 2:14am UTC](https://discourse.julialang.org/t/match-alternative-catchall/89426 "2022-10-31T02:14:13Z")

</div>

I’d like to use @match within @chain @rtransform, but both the MLStyle and Match versions use \_ as the catchall which causes an error as its used by @chain. Is there an alternative catchall in any @match package? @ch…

---

## [@match string startswith endswith](https://discourse.julialang.org/t/match-string-startswith-endswith/87797)

<div class="topic-metadata">

**Author:** [@Lincoln\_Hannah](https://discourse.julialang.org/u/Lincoln_Hannah)\
**Replies:** 4\
**Last updated:** [October 19, 2022, 3:53am UTC](https://discourse.julialang.org/t/match-string-startswith-endswith/87797 "2022-10-19T03:53:10Z")

</div>

Is there a @match equivalent of this? type = startswith(ticker,"ABC") ? "M1" : startswith(ticker,"X") ? "M2" : contains(ticker,"123") ? "M3" : endswith(ticker,"end") …

---

## [Packages for text matching?](https://discourse.julialang.org/t/packages-for-text-matching/60012)

<div class="topic-metadata">

**Author:** [@Lincoln\_Hannah](https://discourse.julialang.org/u/Lincoln_Hannah)\
**Replies:** 15\
**Last updated:** [April 26, 2021, 8:49am UTC](https://discourse.julialang.org/t/packages-for-text-matching/60012 "2021-04-26T08:49:14Z")

</div>

I’d like to write: "$(First\_Name).$(Last\_Name),$(Age)" = "John.Smith,20" with result (First\_Name = "John", Last\_Name = "Smith", Age = 20 ) Any package that supports this pattern matching in text?

---

## [@match type?](https://discourse.julialang.org/t/match-type/1232)

<div class="topic-metadata">

**Author:** [@stustd](https://discourse.julialang.org/u/stustd)\
**Replies:** 4\
**Last updated:** [January 5, 2017, 8:28am UTC](https://discourse.julialang.org/t/match-type/1232 "2017-01-05T08:28:02Z")

</div>

I’m utterly confused why the following code doesn’t produce identical results (i.e. selecting on type with @match (Match.jl) or if…elseif…end). With @match (get\_fmt1) regardless of the actual type, always an integer type…
