Skip to content

Instantly share code, notes, and snippets.

View RichardLitt's full-sized avatar

Richard Littauer RichardLitt

View GitHub Profile
import numpy as np
import matplotlib.pyplot as plt
from sklearn import datasets
# Load Iris dataset
iris = load_penguins()
# Set up the figure size and subplots
fig, axarr = plt.subplots(4, 4, figsize=(12, 12)) # 4x4 grid for 4 features
@RichardLitt
RichardLitt / gist:6b0e442dbc2fefa9f69fb153b8afd7d4
Created January 31, 2024 14:25
Get recent checklist feed in R
# Load necessary library
library(httr)
# Retrieve the eBird API Token from the environment variable
ebird_api_token <- Sys.getenv("EBIRD_API_TOKEN")
# Check if the token is not empty
if (nzchar(ebird_api_token) == FALSE) {
stop("eBird API token not found. Please make sure EBIRD_API_TOKEN is set.")
}
season,year,detector,species,site,date,recording_start,recording_length,detection_time,real_detection_time,real_detection_time,rounded_to_half_hour,duplicate,sunset,civil_dusk,nautical_dusk,astronomical_dusk,astronomical_dawn,nautical_dawn,civil_dawn,sunrise,moon_altitude,moon_illumination
Spring,2023,,passeriformes,Queens,05/01/23,01:00:00,0:29:55,0:10:02,07:10:02,05/02/23 07:10:02,07:00:00,no,05/01/23 19:51:42,05/01/23 20:21:29,05/01/23 20:57:51,05/01/23 21:37:14,05/02/23 04:07:43,05/02/23 04:47:06,05/02/23 05:23:27,05/02/23 05:53:13,-29.0,88.8
Spring,2023,,savs,Queens,05/01/23,01:30:00,0:29:55,0:17:53,07:47:52,05/02/23 07:47:52,08:00:00,no,05/01/23 19:51:42,05/01/23 20:21:29,05/01/23 20:57:51,05/01/23 21:37:14,05/02/23 04:07:43,05/02/23 04:47:06,05/02/23 05:23:27,05/02/23 05:53:13,-34.8,88.9
Spring,2023,,savs,Queens,05/01/23,01:30:00,0:29:55,0:17:55,07:47:54,05/02/23 07:47:54,08:00:00,yes,05/01/23 19:51:42,05/01/23 20:21:29,05/01/23 20:57:51,05/01/23 21:37:14,05/02/23 04:07:43,05/02/23 04:47:06,05/02/23 05
globals:
annotation_name: Classification
annotation_scope: Selection
commands:
">": [show_next_page]
"<": [show_previous_page]
".": [select_next_clip]
",": [select_previous_clip]
# This script grabs totals for contributors for the OrbitDB organization for a three month period.
# It needes to be edited, but keeping this here for next time should save some life.
# This could easily be extended elsewhere.
# npm i -g name-your-contributors
# You will also need to have [`jq`](https://stedolan.github.io/jq/download/) installed.
# brew install jq
# Fix these to match the current month
# TODO Automate monthly so you don't need to do 'before' and 'after'
@RichardLitt
RichardLitt / business-models.md
Created November 6, 2019 15:25
Business models for the decentralized Web

Business models for the decentralized Web

  • SUB-GROUP 1 w/ Ade

Why are centralied models so popular?

  • historical
  • lower cost per transaction
21:00 ~ 🦉 cat testfile | xargs -n1 npm-name
⚠ 1 is squatted
✖ 2 is unavailable
✖ 3 is unavailable
⚠ 4 is squatted
⚠ 5 is squatted
⚠ 6 is squatted
⚠ 7 is squatted
⚠ 8 is squatted
⚠ 9 is squatted
@RichardLitt
RichardLitt / blogpost.md
Created October 2, 2019 14:47
blogpost

OrbitDB v0.22

It's a lot faster and there are more cool options

We're releasing v0.22 today! The last release was on [TR], and the OrbitDB team has been working hard since then to make sure that this next release makes OrbitDB faster, easier, and more delightful to work with. Here's the tl;dr:

  • Significant performance improvements (by significant, we mean 10x)
  • Better concurrency across the board
  • Lots of small bug fixes and a few option improvements
@RichardLitt
RichardLitt / github.md
Created September 30, 2019 20:32
How to be awesome on GitHub

How to be awesome on GitHub

These are my rough notes from a private event I held today around how to set up your GitHub repository to maximise community contributions and reach. Any thoughts on these would be interesting to me!

  • A license file
    • Without this, there is no open source
    • The license will predicate only the code in that repo, not the rest
    • MIT vs GPL vs Apache vs WTFPL
    • Updating year and contributors
  • A good README
### How to be awesome on GitHub
- A license file
- Without this, there is no open source
- The license will predicate only the code in that repo, not the rest
- MIT vs GPL vs Apache vs WTFPL
- Updating year and contributors
- A good README
- Standard-readme https://github.com/noffle/art-of-readme