Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Rで家を光らせる / tokyor90_r2hue

Rで家を光らせる / tokyor90_r2hue

Tokyo.R#90 https://tokyor.connpass.com/event/204802/ での発表スライド
r2hueパッケージ https://github.com/uribo/r2hue 🌟

Uryu Shinya

March 06, 2021
Tweet

More Decks by Uryu Shinya

Other Decks in Technology

Transcript

  1. δϣόϯχ͕Ұ൩Ͱ΍ͬͨ # র໌Λ఺౮ hue_lights_state(id = 1, on = TRUE, xy

    = c(0.144041, 0.187314)) # র໌Λফ౮ hue_lights_state(id = 1, on = FALSE) r2hue::hue_lights_state("uribo/r2hue") library(r2hue)
  2. δϣόϯχ͕Ұ൩Ͱ΍ͬͨ # ॲཧͷޙʹ఺౮ mean(c(2, 3, 4)) %>% light_switch(id = 4,

    on = TRUE) # ॲཧ಺༰ͷঢ়ଶग़ྗͱಉ࣌ʹ఺౮ flash(id = 2, type = "abort", message = "Τϥʔग़ྗͰ੺͘఺౮")
  3. ࣮૷ͷίπ VSJCPDPMPSJOGP MBUFS SMBOH STUVEJPBQJ xy = c(0.144041, 0.187314) xy

    = colorinfo::col2xy("#08A0FF")) flatten_dbl ( DMJ later::later( ~ hue_lights_state( id = id, on = on, ... ), delay = delay) IVFʹૹΔ৭ͷࢦఆ ॲཧ࣮ߦޙʹর໌ૢ࡞