How to make Bullet charts in plotly?

This recipe helps you make Bullet charts in plotly

Recipe Objective

How to make Bullet charts in plotly.

Bullet charts It is used to replace dashboard guages and meters, combining both types of charts into simple bar charts with qualitative bars which are nothing but the steps, quantitative bar which are nothing but the bar and performance line which is threshold all into one simple layout. The steps typically are broken into several values, which are defined with an array. The bar represents the actual value that a particular variable reached, and the threshold usually indicate a goal point relative to the value achieved by the bar.

Step 1 - Import library

import plotly.graph_objects as go

Step 2 - Plot graph

fig = go.Figure(go.Indicator( mode = "number+gauge+delta", gauge = {'shape': "bullet"}, value = 320, delta = {'reference': 400}, domain = {'x': [0, 1], 'y': [0, 1]}, title = {'text': "Profit"})) fig.update_layout(height = 280) fig.show()

What Users are saying..

profile image

Gautam Vermani

Data Consultant at Confidential
linkedin profile url

Having worked in the field of Data Science, I wanted to explore how I can implement projects in other domains, So I thought of connecting with ProjectPro. A project that helped me absorb this topic... Read More

Relevant Projects

LLM Project to Build and Fine Tune a Large Language Model
In this LLM project for beginners, you will learn to build a knowledge-grounded chatbot using LLM's and learn how to fine tune it.

Deep Learning Project for Beginners with Source Code Part 1
Learn to implement deep neural networks in Python .

Expedia Hotel Recommendations Data Science Project
In this data science project, you will contextualize customer data and predict the likelihood a customer will stay at 100 different hotel groups.

Stock Price Prediction Project using LSTM and RNN
Learn how to predict stock prices using RNN and LSTM models. Understand deep learning concepts and apply them to real-world financial data for accurate forecasting.

Locality Sensitive Hashing Python Code for Look-Alike Modelling
In this deep learning project, you will find similar images (lookalikes) using deep learning and locality sensitive hashing to find customers who are most likely to click on an ad.

Loan Default Prediction Project using Explainable AI ML Models
Loan Default Prediction Project that employs sophisticated machine learning models, such as XGBoost and Random Forest and delves deep into the realm of Explainable AI, ensuring every prediction is transparent and understandable.

Build Real Estate Price Prediction Model with NLP and FastAPI
In this Real Estate Price Prediction Project, you will learn to build a real estate price prediction machine learning model and deploy it on Heroku using FastAPI Framework.

Recommender System Machine Learning Project for Beginners-1
Recommender System Machine Learning Project for Beginners - Learn how to design, implement and train a rule-based recommender system in Python

Build a Graph Based Recommendation System in Python-Part 2
In this Graph Based Recommender System Project, you will build a recommender system project for eCommerce platforms and learn to use FAISS for efficient similarity search.

Demand prediction of driver availability using multistep time series analysis
In this supervised learning machine learning project, you will predict the availability of a driver in a specific area by using multi step time series analysis.