Git Product home page Git Product logo

noah's Introduction

Hi there ๐Ÿ‘‹

Here's some stuff I care about:

R Programming

Data Visualization

Learning new Technology

  • ๐Ÿงฎ I'm working through the book D3 for the impatient on ObservableHQ

  • ๐ŸŒฑ Iโ€™m learning Typescript and Svelte by building an online card game

  • ๐ŸŒฑ I'm learning three.js by following Bruno Simon's course.

Presentations & Publications

Contact me!

noah's People

Contributors

teebusch avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

noah's Issues

customizable random seed for Ark?

If the user wants the ark to be reproducible without storing it somewhere, it should be enough to use a random seed.
It's possible for the user to do this themselves, but adding it as a function argument .random_seed = NULL might still be more convenient.

allow customizing built-in data

Some of the adjectives or animals could be perceived as offensive or irritating when used in a more serious context. It would be nice to have a way to customize the word lists.

  • Perhaps a "family-friendly" word list should be provided?
  • Perhaps, the data should be made external (user-accessible), so that it can be modified (filtered) easily by the user?

Get only alliterations from existing "non-alliterating" ark

currently the only way to make alliterations is to create an ark with Ark$new(alliterate = TRUE). Then all pseudonyms from that Ark will be alliterations. It would be better to be able to temporarily request only alliterations from an existing Ark.

permute index using generator-like function

Currently, the pseudonym name parts are shuffled using index_shuffled, which is integer vector, containing a permutation of the index (from 1 to max_length). This permutation is stored with the Ark object.
This is feasible as long as max_length isn't too large (i.e., the number of name parts is small). However, as max_length increases, the memory use will increase. Many of the stored indices may never be used.
A more efficient way to store the permutation could be a generator-like function, that yields a new (unique) random value from the range 1:max_length whenever one is requested.

Add pckdown

A pckdown page bundles the documentation in a easily accessible format and is generated automatically from the package. It would be good to have one.

Add alliteration info to print function

  • The print function should show the settings of the Ark (currently, whether it alliterates by default)
  • The print function should make clear how many alliterations are left in the ark, and how many psudonyms are in it in total.

equivalent integers and floats don't get the same key

R creates floats by default when using single numbers, but integers when using the range notation 1:3.
This creates unexpected behaviour:

library(noah)
ark <- Ark$new(parts = list(
  foo = c("one", "two", "three"),
  bar = c("fi", "fa", "fu")
))
max_total <- 9
ark$pseudonymize(1:5)
#> [1] "Two Fi"   "Three Fi" "Two Fu"   "Three Fa" "One Fi"
ark$pseudonymize(5L)  # gets theexisting pseudonym for 5
#> [1] "One Fi"
ark$pseudonymize(5)   # gets new pseudonym
#> [1] "Three Fu"
print(ark)
#> # An Ark: 6 / 9 pseudonyms used (1%)
#>   key         pseudonym
#>   <md5>       <Attribute Animal>
#> 1 14fa27a6... Three Fu
#> 2 216deaa6... Two Fi
#> 3 3297603a... One Fi
#> 4 8357d673... Three Fi
#> 5 9380ec58... Three Fa
#> 6 ee415bd5... Two Fu

Custom name parts

Instead of the default (adjective animal) there should be an option to supply your own name parts when the ark is created. This would also allow tests that run more quickly.

Encode index more efficiently

Currently the shuffled index is stored as a a:n numerical vector, wasting a lot of space. One could use a combination of FIsher-Yates random sampling and run length encoding to save memory

create hex image

It seems like every real package needs a hex sticker nowadays. How about a boat with some happy animals on it? SOmething friendly and silly. Abyss free font maybe?

add option to return only alliterations

Alliterations are more fun and may be easier to remember. The pseudonymize() function should have an option to return only pseudonyms with alliterations.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.