Function | Shortcut |
---|---|
Previous Tab | ⌘ + Left Arrow |
Next Tab | ⌘ + Right Arrow |
Go to Tab | ⌘ + Number |
Go to Window | ⌘ + Option + Number |
Go to Split Pane by Direction | ⌘ + Option + Arrow |
Go to Split Pane by Order of Use | ⌘ + ] , ⌘ + [ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" Trains an agent with (stochastic) Policy Gradients on Pong. Uses OpenAI Gym. """ | |
import numpy as np | |
import cPickle as pickle | |
import gym | |
# hyperparameters | |
H = 200 # number of hidden layer neurons | |
batch_size = 10 # every how many episodes to do a param update? | |
learning_rate = 1e-4 | |
gamma = 0.99 # discount factor for reward |
See https://yihui.shinyapps.io/voice for the live demo. Make sure you have turned on your microphone and allow the web browser to have access to it. Credits go to annyang and also to @wch for showing me a minimal Shiny example. You can do four things on the scatterplot using your voice input:
- say "title something" to change the plot title, e.g.
title good morning
- say "color a color name" to change the color, e.g.
color blue
- say "bigger" or "smaller" to change the size of points
- say "regression" to add a linear regression line
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.