Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8731869
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T09:20:06+00:00 2026-06-13T09:20:06+00:00

I have data as those ones a b c d e alpha 5.51 0.60

  • 0

I have data as those ones

        a       b       c       d       e
alpha   5.51    0.60    -0.12   26.90   76284.53
beta    3.39    0.94    -0.17   -0.20   -0.20
gamma   7.98    3.34    -1.41   7.74    28394.93
delta   2.29    1.24    0.40    0.29    0.28

I want to do a nice publishable histogram as this one interlaced colorbar histogram

but with a break in the y axis so we can figure out the variation of a , b , c , d and e so that data will not be squashed by extreme values in e column as this one but using interlaced colorbar histogram:
breaking y axis

I would like to do that in python (matplotlib, pandas, numpy/scipy) or in mathematica… or any other open and free high-level language (R, scilab, …). Thanks for your help.

edit: using matplotlib through pandas allows to adjust the space between the two subgraph using option button at bottom left “hspace”.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T09:20:07+00:00Added an answer on June 13, 2026 at 9:20 am

    Have you seen this example? It’s for a broken y-axis plot in matplotlib.

    Hope this helps.

    Combining with pandas this gives:

    import pandas as pd
    import matplotlib.pyplot as plt
    from StringIO import StringIO
    
    data = """\
            a       b       c       d       e
    alpha   5.51    0.60    -0.12   26.90   76284.53
    beta    3.39    0.94    -0.17   -0.20   -0.20
    gamma   7.98    3.34    -1.41   7.74    28394.93
    delta   2.29    1.24    0.40    0.29    0.28
    """
    
    df = pd.read_csv(StringIO(data), sep='\s+')
    
    f, axis = plt.subplots(2, 1, sharex=True)
    df.plot(kind='bar', ax=axis[0])
    df.plot(kind='bar', ax=axis[1])
    axis[0].set_ylim(20000, 80000)
    axis[1].set_ylim(-2, 30)
    axis[1].legend().set_visible(False)
    
    axis[0].spines['bottom'].set_visible(False)
    axis[1].spines['top'].set_visible(False)
    axis[0].xaxis.tick_top()
    axis[0].tick_params(labeltop='off')
    axis[1].xaxis.tick_bottom()
    d = .015
    kwargs = dict(transform=axis[0].transAxes, color='k', clip_on=False)
    axis[0].plot((-d,+d),(-d,+d), **kwargs)
    axis[0].plot((1-d,1+d),(-d,+d), **kwargs)
    kwargs.update(transform=axis[1].transAxes)
    axis[1].plot((-d,+d),(1-d,1+d), **kwargs)
    axis[1].plot((1-d,1+d),(1-d,1+d), **kwargs)
    plt.show()
    

    enter image description here

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a multidocument application. I want to pull data from each of those
I have data about colors. Some of those colors consist of a number of
i have tons of data that i would like to highlight only those cell
i have data-grid in my application and i want to customize my data-grid so
I have 'data.xlsx' file with cells of numbers and letters. when I run this
I have an Oracle table with data that looks like this: ID BATCH STATUS
I have a data that arrives in this format: [ (1, 000010101001010101011101010101110101, aaa, ...
I want to have an class like this, public class Apple { public string
I have these two data structures that I continually find myself choosing between when
I have a DataTable which I select from database (Well, these data cross several

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.