SWISS::GN(3pm)

πŸ“¦
version 1.80 Β· 2 versions
, in debian bookworm, debian trixie, ubuntu jammy, ubuntu noble

🌸 SWISS::GN πŸ’–

okay bestie, gather round, because we're talking about SWISS::GN, a lil Perl module from the User Contributed Perl Documentation collection, and honestly? it's giving ✨specialist✨. no cap.


πŸŽ€ Name πŸŽ€

SWISS::GN.pm β€” yes that's the whole name, she's lowkey mysterious like that πŸ’…


πŸ¦‹ Description πŸ¦‹

so basically SWISS::GN represents one single gene name from the GN line. that's it. that's her job. one gene name, done immaculately. πŸ‘‘

and if you're out here like "okay but what if I have, like, several synonym gene names" β€” bestie, that's a whole different girl. the container object for several synonym gene names is SWISS::GeneGroup. she's the group chat; SWISS::GN is the one-on-one. 🌈


🌟 Inherits from 🌟

SWISS::BaseClass.pm β€” yeah she got it from her mama, iconic lineage fr fr πŸ’œ


πŸ“ Attributes πŸ“

  • text β€” literally just one gene name. that's the whole attribute. one name, living her best life. πŸ’–

🧚 Methods 🧚

⭐ Standard methods ⭐

the basics, the essentials, the main character trio:

  • new
  • fromText
  • toText

no notes. periodt. πŸ’…


πŸ’« Reading/Writing methods πŸ’«

🌸 toMixedCase(@regexps) 🌸

okay so this one is the fun one, and the way that she works is: she converts gene names to mixed case, according to one or more regular expressions. you pass in @regexps β€” one or more of them, your call, bestie. 🫢

this is typically useful for converting uppercase ORF numbers to mixed case. very glow-up, very makeover-montage energy. ✨

example time, because i know you love an example:

  • the E.coli gene "B1563", converted with the regexp '(b(\d{4}(\.\d)?))', will yield the gene name "b1563". slay. πŸ”₯

and she's not even done β€” the method also supports fused gene names. so like, "B0690/B0691" gets converted to "b0690/b0691". both of them. together. no gene left behind. πŸ˜­πŸ’–

heads up: the method changes the text of the SWISS::GN object and also returns the new text value. so she's doing both. overachiever behavior, we love to see it. πŸ‘‘

and that's the whole page, bestie! this gorgeous little manual came to you from perl v5.32.1, dated 2021-08-15, so if you ever need to cite her, that's the receipt πŸ§ΎπŸ’œ mwah, study safe, hydrate, and may all your ORF numbers be mixed case πŸŒˆπŸ’…πŸŽ€

πŸ“¦ where this page comes from