nihilism is exhausting
Setting this up was a nightmare of broken dependencies, but I finally found the magic formula (macOS and Linux). 1. Install miniconda from:https://www.anaconda.com/docs/getting-started/miniconda/install#macos-linux-installation 2. Insert these into requirements.txt… 3. Once installed…. ..and run this test python3 script.
Group all the records by the smiles column, count the number of occurrences for each unique SMILES string, and then filter the results to show only those strings that appear more than once… Show how many records in total exist in your table and then subtracts the number of unique SMILES strings. The result is…
-i.bak makes sure of a backup, because this is a risky operation. It is required with the -i flag on macOS/BSD.
Removes lines from a tab-delimited file where the (sub)string “Error” appears in the 4th column/field.
Pipe a SMILES string into Python query to RDkit and prints the result…
May be too aggressive in some cases, AWK may be more precise for this task in tab-delimited files.
…preserves line order
In a typical fit of hubris, I’ve embarked on an ambitious project to build a predictive toxicology suite using open source chemoinformatics tools and the wads of data I’ve collected over the past 20-odd years. Due to the complexity involved, I have co-opted Google Gemini’s LLMs to help me setting up environments, refactoring old code…
Tips for Giving/Receiving Directions in Greece: Be patient: Not everyone speaks English, especially in more rural areas. Body language helps: Pointing, using hand gestures for turns, and indicating “straight” can be very effective. Pronunciation: Don’t worry about perfect pronunciation, but try your best. Greeks appreciate the effort. Place names: If you have the name of…
Getting Attention / Ordering: More Specific Orders / Quantities: Questions / Preferences: During / After Drinking: Paying: Other Useful Phrases: Pronunciation Tips: Even trying a few of these phrases will likely be appreciated! Καλή διασκέδαση! (Kalí dhiaskédhasi! – Have fun!) I need a drink. Χρειάζομαι ένα ποτό. Chreiázomai éna potó. I need to get drunk.…
They serve very different purposes but are used together when handing database queries. Struct (Structure) Example: Vec (Vector) Example: Summary Table: Feature struct Vec<T> Purpose Define a custom type with fixed fields Store a variable-length list of elements Members Fields Elements Member Types Can be different Must be the same (T) Size Fixed number of fields (compile-time) Variable…
Think of an enum as defining a set of named constants that represent all the possible values a type can have. However, Rust enums go beyond simple named constants found in many other languages by allowing variants to hold associated data. Core Concepts: Basic Syntax: Enums with Associated Data: This is where Rust enums really shine.…
Rust provides a rich set of methods for string manipulation, primarily through the &str (string slice) primitive type and the String (owned, growable string) type from the standard library. Since String implements Deref<Target = str>, most methods available on &str can also be called directly on String. Here’s a comprehensive list, categorized for clarity: I. Creation & Conversion II. Length & Capacity III. Appending &…
I. Primitive Types (Built-in) These are the fundamental building blocks. II. Compound Types (Built-in) These group other values together. III. Standard Library Collections (std::collections) These are more flexible, often heap-allocated structures. IV. User-Defined Types You define these yourself using keywords. V. Slices (Borrowed Views) This list covers the most commonly encountered data structures. The choice…
"Life goes on, man."