attachment
attachment

Make is flowchart form and give also easy point to understand in simple way. Give the short information about each main points and subpoints (2 to 3 points) At the end create image in JPG format

Running Command

mkdir -p /home/daytona/workspace/protein-flowchart && ls /home/daytona/workspace/protein-flowchart/

Writing File

~/protein-flowchart/flowchart.py

import matplotlib
matplotlib.use('Agg')
import matplotlib.pyplot as plt
import matplotlib.patches as mpatches
from matplotlib.patches import FancyBboxPatch, FancyArrowPatch

fig, ax = plt.subplots(figsize=(28, 48))
ax.set_xlim(0, 28)
ax.set_ylim(0, 48)
ax.axis('off')
fig.patch.set_facecolor('#F0F4FF')

# ─── Helper functions ───────────────────────────────────────────────
def box(ax, x, y, w, h, text, fc='#2C3E7A', tc='white', fs=11, fw='bold',
        style='round,pad=0.1', ec='#1A255A', lw=1.5, ha='center', va='center', wrap=False):
    rect = FancyBboxPatch((x - w/2, y - h/2), w, h,
                          boxstyle=style, facecolor=fc, edgecolor=ec, linewidth=lw, zorder=3)
    ax.add_patch(rect)
    ax.text(x, y, text, color=tc, fontsize=fs, fontweight=fw,
            ha=ha, va=va, zorder=4, wrap=wrap,
            multialignment='center')

def arrow(ax, x1, y1, x2, y2, color='#555555'):
    ax.annotate('', xy=(x2, y2), xytext=(x1, y1),
                arrowprops=dict(arrowstyle='->', color=color, lw=2.0), zorder=2)

def info_box(ax, x, y, w, h, title, bullets, fc='#EAF4FB', tc='#1A3A6C', ts=9.5, bs=8.8):
    rect = FancyBboxPatch((x - w/2, y - h/2), w, h,
                          boxstyle='round,pad=0.08', facecolor=fc, edgecolor='#7EB6D9', linewidth=1.2, zorder=3)
    ax.add_patch(rect)
    ax.text(x, y + h/2 - 0.22, title, color=tc, fontsize=ts, fontweight='bold',
            ha='center', va='top', zorder=4)
    for i, b in enumerate(bullets):
        ax.text(x - w/2 + 0.18, y + h/2 - 0.55 - i*0.38, f'• {b}',
                color='#333333', fontsize=bs, ha='left', va='top', zorder=4)

# ═══════════════════════════════════════════════════════
# TITLE
# ═══════════════════════════════════════════════════════
box(ax, 14, 47.0, 26, 0.9,
    'A. Classification of Proteins by Physicochemical Properties',
    fc='#1A3A6C', tc='white', fs=14, fw='bold', lw=2.5)

arrow(ax, 14, 46.55, 14, 45.95)

# ═══════════════════════════════════════════════════════
# THREE MAIN CATEGORIES
# ═══════════════════════════════════════════════════════
# 1. Simple Proteins
box(ax, 4.5, 45.5, 7.5, 0.75, '1. Simple Proteins', fc='#1976D2', tc='white', fs=12)
# 2. Conjugated Proteins
box(ax, 14, 45.5, 7.5, 0.75, '2. Conjugated Proteins', fc='#388E3C', tc='white', fs=12)
# 3. Derived Proteins
box(ax, 23.5, 45.5, 7.5, 0.75, '3. Derived Proteins', fc='#7B1FA2', tc='white', fs=12)

# connectors from title to 3 cats
ax.annotate('', xy=(4.5, 45.87), xytext=(14, 46.55),
            arrowprops=dict(arrowstyle='->', color='#555', lw=1.8))
ax.annotate('', xy=(14, 45.87), xytext=(14, 45.95),
            arrowprops=dict(arrowstyle='->', color='#555', lw=1.8))
ax.annotate('', xy=(23.5, 45.87), xytext=(14, 46.55),
            arrowprops=dict(arrowstyle='->', color='#555', lw=1.8))

# ═══════════════════════════════════════════════════════
# ── 1. SIMPLE PROTEINS ──
# ═══════════════════════════════════════════════════════
# a) Globular
box(ax, 4.5, 44.6, 6.5, 0.65, 'a) Globular Proteins', fc='#42A5F5', tc='white', fs=10.5)
arrow(ax, 4.5, 45.12, 4.5, 44.93)

# info box for globular
info_box(ax, 4.5, 43.3, 6.8, 1.6,
         'Globular Proteins',
         ['Soluble in water/salt solutions',
          'Spherical/elliptical shape',
          'e.g. Albumins, Globulins, Histones, Lectins'])
arrow(ax, 4.5, 44.27, 4.5, 44.1)

# sub-items globular
globular_items = ['i) Albumins', 'ii) Globulins', 'iii) Glutelins',
                  'iv) Prolamines', 'v) Protamines',
                  'vi) Histones', 'vii) Globins', 'viii) Lectins']
glob_descriptions = [
    'Blood plasma protein;\nmaintains osmotic pressure',
    'Immune proteins;\nmake antibodies',
    'Plant storage proteins;\ne.g. wheat glutenin',
    'Rich in proline;\nfound in cereal seeds',
    'Small, basic proteins;\nbind nucleic acids',
    'Bind DNA in nucleosomes;\nregulate gene expression',
    'Oxygen-carrying proteins;\ne.g. hemoglobin subunits',
    'Bind carbohydrates;\ncell recognition proteins',
]
start_y = 42.0
for i, (item, desc) in enumerate(zip(globular_items, glob_descriptions)):
    cy = start_y - i * 1.2
    box(ax, 3.2, cy, 4.5, 0.55, item, fc='#BBDEFB', tc='#1A3A6C', fs=9, fw='bold', ec='#90CAF9')
    # description beside
    ax.text(5.6, cy, desc, color='#333', fontsize=8, ha='left', va='center', zorder=4,
            bbox=dict(boxstyle='round,pad=0.15', fc='#E3F2FD', ec='#90CAF9', lw=0.8))
    if i == 0:
        arrow(ax, 4.5, 42.42, 4.5, 42.27)
    else:
        arrow(ax, 3.2, cy + 0.575, 3.2, cy + 0.28)

# b) Fibrous
fib_y = start_y - len(globular_items)*1.2 - 0.3
box(ax, 4.5, fib_y, 6.5, 0.65, 'b) Fibrous Proteins', fc='#1565C0', tc='white', fs=10.5)
arrow(ax, 3.2, fib_y + 0.85, 3.2, fib_y + 0.33)

info_box(ax, 4.5, fib_y - 1.0, 6.8, 1.5,
         'Fibrous Proteins',
         ['Insoluble, elongated shape',
          'Structural/mechanical roles',
          'e.g. Collagen, Elastin, Keratin'])
arrow(ax, 4.5, fib_y - 0.33, 4.5, fib_y - 0.25)

fibrous_items = [
    ('i) Collagen\n(connective tissue)',
     'Most abundant protein;\nbone, skin, tendons'),
    ('ii) Elastin\n(connective tissue)',
     'Elastic recoil in skin,\narteries, lungs'),
    ('iii) Keratin\n(ectodermal tissue)',
     'Nails, hair, hoofs;\nprotective barrier'),
]
for j, (item, desc) in enumerate(fibrous_items):
    cy = fib_y - 1.85 - j*1.15
    box(ax, 3.2, cy, 4.5, 0.65, item, fc='#BBDEFB', tc='#1A3A6C', fs=8.5, fw='bold', ec='#90CAF9')
    ax.text(5.6, cy, desc, color='#333', fontsize=8, ha='left', va='center', zorder=4,
            bbox=dict(boxstyle='round,pad=0.15', fc='#E3F2FD', ec='#90CAF9', lw=0.8))
    if j == 0:
        arrow(ax, 4.5, fib_y - 1.25, 4.5, fib_y - 1.52)
    else:
        arrow(ax, 3.2, cy + 0.73, 3.2, cy + 0.33)

# ═══════════════════════════════════════════════════════
# ── 2. CONJUGATED PROTEINS ──
# ═══════════════════════════════════════════════════════
conj_items = [
    ('i) Nucleoproteins',
     'Nucleohistones,\nnucleoprotamines;\nbind DNA/RNA'),
    ('ii) Glycoproteins',
     'Mucins, Immunoglobulins,\nComplements;\ncell surface recognition'),
    ('iii) Mucoproteins\n(Mucoids)',
     'Mucin (saliva), blood group\nsubstances, FSH, LH;\nhigh CHO content'),
    ('iv) Lipoproteins',
     'LDL, VLDL, HDL;\ntransport fats in blood'),
    ('v) Phosphoproteins',
     'Casein (milk), vitellin\n(egg yolk);\nstore phosphate'),
    ('vi) Chromoproteins',
     'Hemoglobin, flavoproteins,\nrhodopsin;\ncolored prosthetic group'),
    ('vii) Metalloproteins',
     'Ferritin (Fe),\nCeruloplasmin (Cu);\nbind metal ions'),
]

arrow(ax, 14, 45.12, 14, 44.55)
for k, (item, desc) in enumerate(conj_items):
    cy = 44.2 - k * 1.55
    box(ax, 12.5, cy, 5.0, 0.75, item, fc='#A5D6A7', tc='#1B5E20', fs=9, fw='bold', ec='#66BB6A')
    ax.text(15.15, cy, desc, color='#333', fontsize=8, ha='left', va='center', zorder=4,
            bbox=dict(boxstyle='round,pad=0.15', fc='#E8F5E9', ec='#81C784', lw=0.8))
    if k == 0:
        arrow(ax, 14, 44.55, 14, 44.58)
    else:
        arrow(ax, 12.5, cy + 0.78, 12.5, cy + 0.38)

# ═══════════════════════════════════════════════════════
# ── 3. DERIVED PROTEINS ──
# ═══════════════════════════════════════════════════════
arrow(ax, 23.5, 45.12, 23.5, 44.55)

# a) Primary Derived
box(ax, 23.5, 44.2, 6.5, 0.65, 'a) Primary Derived Proteins', fc='#CE93D8', tc='white', fs=10, fw='bold')
arrow(ax, 23.5, 44.55, 23.5, 44.53)

info_box(ax, 23.5, 43.1, 6.8, 1.5,
         'Primary Derived',
         ['Formed by mild denaturation',
          'Native structure slightly altered',
          'e.g. Coagulated proteins, Proteans'])
arrow(ax, 23.5, 43.87, 23.5, 43.85)

prim_items = [
    ('i) Coagulated Proteins',
     'Insoluble after heat/acid;\ne.g. boiled egg white'),
    ('ii) Proteans',
     'First products of\nprotein hydrolysis;\nslightly insoluble'),
    ('iii) Metaproteins',
     'Formed by strong acid/alkali;\nsoluble in weak acids/bases'),
]
for m, (item, desc) in enumerate(prim_items):
    cy = 42.4 - m * 1.2
    box(ax, 22.2, cy, 4.5, 0.65, item, fc='#F3E5F5', tc='#4A148C', fs=9, fw='bold', ec='#CE93D8')
    ax.text(24.55, cy, desc, color='#333', fontsize=8, ha='left', va='center', zorder=4,
            bbox=dict(boxstyle='round,pad=0.15', fc='#F3E5F5', ec='#CE93D8', lw=0.8))
    if m == 0:
        arrow(ax, 23.5, 43.35, 23.5, 42.73)
    else:
        arrow(ax, 22.2, cy + 0.73, 22.2, cy + 0.33)

# b) Secondary Derived
sec_y = 42.4 - len(prim_items)*1.2 - 0.5
box(ax, 23.5, sec_y, 6.5, 0.65, 'b) Secondary Derived Proteins', fc='#8E24AA', tc='white', fs=10, fw='bold')
arrow(ax, 22.2, sec_y + 0.9, 22.2, sec_y + 0.33)

info_box(ax, 23.5, sec_y - 1.0, 6.8, 1.5,
         'Secondary Derived',
         ['Formed by prolonged hydrolysis',
          'Smaller fragments than primary',
          'e.g. Proteoses, Peptones, Peptides'])
arrow(ax, 23.5, sec_y - 0.33, 23.5, sec_y - 0.25)

sec_items = [
    ('i) Proteoses\n(Albumoses)',
     'Large hydrolytic fragments;\nsoluble, coagulable'),
    ('ii) Peptones',
     'Smaller than proteoses;\nnot coagulated by heat'),
    ('iii) Peptides',
     'Hydrolytic products of peptones;\nshort amino acid chains'),
]
for n, (item, desc) in enumerate(sec_items):
    cy = sec_y - 1.9 - n * 1.2
    box(ax, 22.2, cy, 4.5, 0.75, item, fc='#F3E5F5', tc='#4A148C', fs=9, fw='bold', ec='#CE93D8')
    ax.text(24.55, cy, desc, color='#333', fontsize=8, ha='left', va='center', zorder=4,
            bbox=dict(boxstyle='round,pad=0.15', fc='#F3E5F5', ec='#CE93D8', lw=0.8))
    if n == 0:
        arrow(ax, 23.5, sec_y - 1.25, 23.5, sec_y - 1.52)
    else:
        arrow(ax, 22.2, cy + 0.78, 22.2, cy + 0.38)

# ═══════════════════════════════════════════════════════
# LEGEND
# ═══════════════════════════════════════════════════════
legend_y = 1.5
legend_items = [
    ('#1976D2', 'Simple Proteins'),
    ('#388E3C', 'Conjugated Proteins'),
    ('#7B1FA2', 'Derived Proteins'),
    ('#42A5F5', 'Sub-category'),
    ('#A5D6A7', 'Conjugated Sub-type'),
    ('#F3E5F5', 'Derived Sub-type'),
]
ax.text(1, legend_y + 0.7, 'Legend:', fontsize=10, fontweight='bold', color='#1A3A6C')
for li, (col, label) in enumerate(legend_items):
    lx = 1 + (li % 3) * 8.5
    ly = legend_y - (li // 3) * 0.55
    rect = FancyBboxPatch((lx - 0.5, ly - 0.18), 0.9, 0.36,
                          boxstyle='round,pad=0.05', facecolor=col, edgecolor='#555', lw=0.8, zorder=3)
    ax.add_patch(rect)
    ax.text(lx + 0.6, ly, label, fontsize=8.5, va='center', color='#333')

# Footer
ax.text(14, 0.4, 'Classification of Proteins by Physicochemical Properties  •  Biochemistry Reference',
        fontsize=9, ha='center', color='#888', style='italic')

plt.tight_layout(pad=0.5)
plt.savefig('/home/daytona/workspace/protein-flowchart/protein_classification_flowchart.jpg',
            dpi=150, format='jpeg', bbox_inches='tight',
            facecolor=fig.get_facecolor())
print("Saved successfully!")
Running Command

cd /home/daytona/workspace/protein-flowchart && python flowchart.py 2>&1

Here's the complete breakdown in easy, simple points, followed by your downloadable flowchart image:

🔬 Classification of Proteins by Physicochemical Properties


1. 🔵 Simple Proteins

Made of only amino acids — no extra components attached.

a) Globular Proteins — Spherical, soluble in water

ProteinKey Points
i) AlbuminsFound in blood plasma; maintain osmotic pressure; most abundant serum protein
ii) GlobulinsMake antibodies (immunoglobulins); found in blood and tissues
iii) GlutelinsPlant storage proteins (e.g., wheat glutenin); insoluble in water
iv) ProlaminesRich in proline amino acid; found in cereal seeds (corn, wheat)
v) ProtaminesSmall, basic proteins; bind tightly to nucleic acids
vi) HistonesWrap DNA in nucleosomes; regulate gene expression
vii) GlobinsSubunits of hemoglobin; carry oxygen in red blood cells
viii) LectinsBind carbohydrates; involved in cell recognition and signaling

b) Fibrous Proteins — Elongated, insoluble, structural role

ProteinKey Points
i) CollagenMost abundant protein in body; found in bone, skin, tendons
ii) ElastinProvides elasticity to skin, arteries, and lungs
iii) KeratinFound in nails, hair, hoofs; forms protective outer layer

2. 🟢 Conjugated Proteins

Proteins attached to a non-protein group (prosthetic group).
TypeProsthetic GroupExamples
i) NucleoproteinsNucleic acids (DNA/RNA)Nucleohistones, nucleoprotamines
ii) GlycoproteinsCarbohydratesMucins, immunoglobulins, complements
iii) MucoproteinsHigh carbohydrate (>4%)Mucin (saliva), blood group substances, FSH, LH
iv) LipoproteinsLipidsLDL, VLDL, HDL — transport fats in blood
v) PhosphoproteinsPhosphoric acidCasein (milk), vitellin (egg yolk)
vi) ChromoproteinsColored prosthetic groupHemoglobin, flavoproteins, rhodopsin
vii) MetalloproteinsMetal ionsFerritin (Fe), Ceruloplasmin (Cu)

3. 🟣 Derived Proteins

Products of hydrolysis or denaturation of native proteins.

a) Primary Derived — mild changes, structure slightly altered

TypeKey Points
i) Coagulated ProteinsFormed by heat/acid; e.g., boiled egg white
ii) ProteansFirst products of hydrolysis; slightly insoluble
iii) MetaproteinsFormed by strong acid/alkali; soluble in weak acids/bases

b) Secondary Derived — further breakdown into smaller fragments

TypeKey Points
i) Proteoses (Albumoses)Large hydrolytic fragments; soluble but coagulable
ii) PeptonesSmaller than proteoses; not coagulated by heat
iii) PeptidesHydrolytic products of peptones; short chains of amino acids

📥 Download Flowchart (JPG)

protein classification flowchart

Image · JPG

The flowchart is organized in 3 color-coded columns:
  • 🔵 Blue = Simple Proteins (Globular + Fibrous)
  • 🟢 Green = Conjugated Proteins (7 types)
  • 🟣 Purple = Derived Proteins (Primary + Secondary)
Each box includes the name, examples, and a 2–3 point description for quick revision!
This is a shared conversation. Sign in to Orris to start your own chat.