[PYTHON] Make a histogram for the time being (matplotlib)

7.3762191e-01
6.9414645e-01
7.2935387e-01
7.2315696e-01
6.9948782e-01
7.0568515e-01
...

Suppose you have data like this

import numpy
from matplotlib import pyplot


def show(filename):
    data = numpy.loadtxt(filename)
    pyplot.hist(data)
    pyplot.show()

When saving to a file

def show(filename):
    data = numpy.loadtxt(filename)
    pyplot.hist(data)
    pyplot.savefig("figure1.eps")

To do. It automatically determines the extension and saves it as eps / png. bin will judge automatically. See the link below for details on how to specify.

References

Recommended Posts

Make a histogram for the time being (matplotlib)
I want to create a Dockerfile for the time being.
Python Master RTA for the time being
For the time being, import them into jupyter
Use logger with Python for the time being
Run yolov4 "for the time being" on windows
I played with Floydhub for the time being
Try using LINE Notify for the time being
virtualenv For the time being, this is all!
If you are a beginner in programming, why not make a "game" for the time being? The story
[Hi Py (Part 1)] I want to make something for the time being, so first set a goal.
Flow memo to move LOCUST for the time being
Run with CentOS7 + Apache2.4 + Python3.6 for the time being
I will install Arch Linux for the time being.
Next to Excel, for the time being, jupyter notebook
Kaguru for the first time
I thought I could make a nice gitignore editor, so I tried to make something like MVP for the time being
Until you run a Flask application on Google App Engine for the time being
I want to move selenium for the time being [for mac]
I tried running PIFuHD on Windows for the time being
[Introduction to Reinforcement Learning] Reinforcement learning to try moving for the time being
For the time being, try using the docomo chat dialogue API
Make a Tweet box for Pepper
[Python] Make the function a lambda function
[For self-learning] Go2 for the first time
See python for the first time
Start Django for the first time
Write a stacked histogram with matplotlib
Java programmer tried to touch Go language (for the time being)
Understanding the python class Struggle (1) Let's move it for the time being
Challenge image classification by TensorFlow2 + Keras 1-Move for the time being-
Let's touch Google's Vision API from Python for the time being
For the time being, I want to convert files with ffmpeg !!
Try using FireBase Cloud Firestore in Python for the time being
I made a function to check if the webhook is received in Lambda for the time being
Randomly play the movie on ChromeCast for a certain period of time
I tried tensorflow for the first time
Challenge image classification with TensorFlow2 + Keras CNN 1 ~ Move for the time being ~
Find the dates for a jarring tournament
A memo when creating an environment that can be debugged with Lambda @ Edge for the time being
Change the list in a for statement
Make a partially zoomed figure with matplotlib
Make Qt for Python app a desktop app
MongoDB for the first time in Python
ROS course 107 Make a client for rosblidge
Let's try Linux for the first time
Make a chessboard pattern for camera calibration
A useful note when using Python for the first time in a while
Make matplotlib look like a flat design
Let's make a Backend plugin for Errbot
Try adding an external module to pepper. For the time being, in requests.
I want to make a music player and file music at the same time
I bought Sipeed Lichee Zero so I set it up for the time being
Let's display a simple template that is ideal for Django for the first time
Turn multiple lists with a for statement at the same time in Python
CCC: coding crash course (4) Make the numbers appearing in pi 3.141562 .... into a histogram
I want to make matplotlib a dark theme
I tried using scrapy for the first time
Pandas basics for beginners ③ Histogram creation with matplotlib
How to use MkDocs for the first time
Make a bot for Skype on EC2 (CentOS)