Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow histogram.py and other scripts to be imported/used as python modules #37

Open
bw2 opened this issue Jul 6, 2016 · 3 comments
Open

Comments

@bw2
Copy link

bw2 commented Jul 6, 2016

Hi, I'd like to generate histograms to standard out in my python script, and currently have to do
os.system("echo '%s' | historgram.py" % "\n".join(values))

It would be great if I could instead do

from data_stacks import histogram
histogram.histogram(values)
@bsergean
Copy link

I'd like to have that too ... I don't think it would be too hard to make a pull request for that I should do that.

@pylipp
Copy link

pylipp commented Feb 21, 2017

You should check out #41, it's pretty handy.

@jkawamoto
Copy link

Thanks for referring the PR. I forgot to mention this issue from that PR.

galpressman added a commit to galpressman/data_hacks that referenced this issue Sep 20, 2017
Running histogram.py on a data file is cool, but most of my
data is kept in local variables in scripts.

Introduce print_histogram function which accepts a list of
samples and prints the same histogram it would as if the list
was exported to a file.

Issue: bitly#37
Signed-off-by: Gal Pressman <[email protected]>
galpressman added a commit to galpressman/data_hacks that referenced this issue Sep 20, 2017
Running histogram.py on a data file is cool, but most of my
data is kept in local variables in scripts.

Introduce print_histogram function which accepts a list of
samples and prints the same histogram it would as if the list
was exported to a file.

Issue: bitly#37
Signed-off-by: Gal Pressman <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

4 participants