stevensanderson, to datascience
@stevensanderson@mstdn.social avatar

Learn how to split strings and get the first element in R using base R, stringi, and stringr. Check out my latest post for examples and tips. Give it a try and share your experiences!

#Rstats #DataScience #StringManipulation #R #RProgramming #stringr #stringi #strings #Programming #Data

Post: https://www.spsanderson.com/steveondata/posts/2024-06-05/

image/png

stevensanderson, to datascience
@stevensanderson@mstdn.social avatar

Learn how to handle rows in R containing specific strings using base R's grep() and dplyr's filter() with str_detect(). Select or drop rows efficiently and enhance your data manipulation skills. Give it a try with your datasets for better data cleaning and organization.

#R

Post: https://www.spsanderson.com/steveondata/posts/2024-05-23/

stevensanderson, to programming
@stevensanderson@mstdn.social avatar

🎉 New Post Alert! 🎉

Counting words in a string is a fundamental task in data analysis.

  1. Base R: Use strsplit(), a straightforward method to split strings and count words.

  2. stringr: The str_split() function from the stringr package makes the code more readable.

  3. stringi: For powerful and efficient string manipulation, stri_split_regex() from the stringi package is your go-to.

Happy coding! 🚀

#R

Post: https://www.spsanderson.com/steveondata/posts/2024-05-16/

damien_dupre,

@stevensanderson what about stringr::str_count(x, "\\w+")?

stevensanderson,
@stevensanderson@mstdn.social avatar

@damien_dupre yes that works too

SharonCummingsArt, to art
@SharonCummingsArt@mastodon.social avatar
SharonCummingsArt, to art
@SharonCummingsArt@socel.net avatar
feinstruktur, to classicalmusic
@feinstruktur@mastodon.social avatar

Karl Amadeus Hartmann: Symphony No. 4 (1946-47)
Performed by the Bamberger Symphoniker
Conducted by Ingo Metzmacher

https://youtu.be/8VoK0neJlq0?si=rqVrCDRcATMT4eu8


@classicalmusic @classical_music_and_beyond

amadeus, to random
@amadeus@mstdn.social avatar

Does anyone know of a decent or ? So far I have only found so-called silent cellos/violins with built-in, synthesized and amplified sound engines. But I'd really be more interested in a pure MIDI controller. The same goes for the . If there's something well-built and reliable in that area, I'd be interested as well. 🤓️

danadamsmusic, to classicalmusic

Miss Admiral Gordon’s Strathspey (William Marshall ) is a 250 yr. old strathspey dance tune. Named for the Strathspey region of Scotland, the strathspey dance is a popular form of country dance, usually in 4/4 time and slower than a reel or jig. It is characterized by the use of the “Scots Snap" rhythm — a sixteenth note followed by a dotted eighth note, or in reverse order.

video/mp4

AnimatedShortOfTheDay, to Canada
@AnimatedShortOfTheDay@socel.net avatar
autumn64, to random

#C : How many times have you struggled with because of memory leaks caused by , or by of your information being incomplete because you didn't choose the right buffer size on ?

Recently I made this header file called .H, which mimics the functionality of the from high-level programming languages. It's easy to use, memory-safe, doesn't need a buffer size, and especially, it's free software!

Check it out here: https://codeberg.org/Autumn64/nsstring.h

roberto, to php

PHP function: levenshtein()

Calculating the distance between two strings

https://drops-of-php.hi-folks.dev/05-string/16-str-levensthein/

magitism,

@roberto Does anyone have a real concrete example of Levenshtein being useful in the wild? I used it once to do a 404 page suggestion system, but other methods ended up being much faster and smarter.

roberto,

@magitism of course, thank you for your reply.
I used it in a command-line tool to find a misspelled option. Generally, it's handy when you have a list and need to pinpoint the closest match to a given input. Fixing a misspelled path against a list of valid paths is another practical use. It's also useful when comparing simplified DNA sequences or finding similar sequences in a series of game steps. While a basic similarity function, it may not be the most effective in all contexts.

ambergrey, to aitools
@ambergrey@mastodon.social avatar

Are guitar luthiering tools the same as violin family luthier tools? Does anyone know how one starts acquiring these over time to build their own workbench to work on both families of instruments?

eighthourlunch,
@eighthourlunch@mastodon.social avatar

@ambergrey It depends on what kind of guitar you're planning on. One thing you'll need for guitars is a fret saw and mitre. I've only been working on electric guitars, and my setup looks like this:

Jig saw
Table saw
Router
Drill press
Wood lathe
Orbital sander
Hand planes
Foredom flex shaft
3d printer for pickups
Soldering iron

The main thing I'm missing for acoustic guitars and violins is a good set of chisels. And talent. :)

GuitarSith,
@GuitarSith@fosstodon.org avatar

@ambergrey
Most of the tools are probably interchangeable. That said I would recommend this company for all your luthier needs.

https://www.stewmac.com/

gregorni, to random
@gregorni@fosstodon.org avatar

Gotta love it when the Gtk docs tell you a function takes a "NULL-terminated array of char*" as a parameter. 😂

(For those who don't know, this is C jargon for "a string")

#C

nigelpurdy, (edited ) to random
svetlyak40wt, to random
@svetlyak40wt@fosstodon.org avatar

Common Lisp Package of the day:

https://github.com/stylewarning/big-string

Go, play with it!

  • All
  • Subscribed
  • Moderated
  • Favorites
  • provamag3
  • thenastyranch
  • magazineikmin
  • ethstaker
  • GTA5RPClips
  • InstantRegret
  • rosin
  • love
  • Youngstown
  • slotface
  • khanakhh
  • kavyap
  • everett
  • DreamBathrooms
  • megavids
  • osvaldo12
  • tester
  • cisconetworking
  • tacticalgear
  • ngwrru68w68
  • Durango
  • cubers
  • mdbf
  • normalnudes
  • anitta
  • modclub
  • Leos
  • JUstTest
  • All magazines