From the sequence pics can you make a good and detailed notes on the systemic examination of respiratory system, so that I can impress my teacher and he must find out it is from MacLeod by the words and please make it same as in the book
'Please say "one, one, one" each time I move my stethoscope'
| Category | Suggestive History | Suggestive Examination |
|---|---|---|
| Infection | ||
| Acute bronchitis | Cough, sputum, wheeze, acute-on-chronic dyspnoea | Polyphonic wheeze |
| Exacerbation of COPD | Cough, mucopurulent sputum, ankle swelling ('cor pulmonale'), headache (hypercapnia) | Hyperinflation, quiet breath sounds, polyphonic wheeze, flapping tremor (CO₂ retention), ankle oedema ('cor pulmonale') |
| Pneumonia | Fever, rigors, pleuritic pain, rusty sputum, loss of appetite | If lobar, dull percussion, bronchial breathing and increased vocal resonance |
| Malignancy | Insidious onset, weight loss, cough, haemoptysis, persisting pain | Cervical lymphadenopathy, finger clubbing, signs of lobar/lung collapse ± effusion |
| Pulmonary fibrosis | Progressive dyspnoea, cough | Tachypnoea, finger clubbing, central cyanosis, inspiratory fine crackles at bases |
| Pleural effusion | Progressive dyspnoea | Unilateral basal dullness and reduced breath sounds |
| Pulmonary embolism | ||
| Large | Sudden severe dyspnoea | Normal breath sounds |
| Medium | Episodes of pleuritic pain, haemoptysis | Pleural rub, crackles if infarct |
| Multiple small | Progressive dyspnoea | Raised JVP, residual volume heave, loud P2 |
| Asthma | Atopy, hay fever, pet ownership, variable wheeze, disturbance of sleep | Polyphonic expiratory wheeze, eczema |
| Problem | Appropriate Initial Investigations | Diagnostic Value |
|---|---|---|
| Infection (e.g. acute bronchitis, exacerbation of COPD, pneumonia) | Chest X-ray | Consolidation in pneumonia |
| O₂ saturation, ABG | Assessment of respiratory failure | |
| Sputum/blood culture | Identify causal infection | |
| WCC, CRP | Degree of inflammation | |
| Malignancy | Chest X-ray | Identification of lesion |
| CT thorax + abdomen | Tumour stage | |
| Bronchoscopy if central | Diagnostic pathology | |
| Endobronchial ultrasound (EBUS) | Allows lymph node sampling | |
| CT-guided biopsy if peripheral | Diagnostic pathology | |
| Respiratory function | Fitness for surgery and radical radiotherapy | |
| Pulmonary fibrosis / interstitial lung disease | Chest X-ray | Bi-basal reticular shadows |
| High-resolution CT thorax | Extent and pattern of disease | |
| Respiratory function | Quantification; identification of restrictive pattern; impaired gas transfer | |
| Exercise test (6 min walk or incremental) | Functional capacity | |
| Autoantibodies | Identification of any associated connective tissue disease | |
| Pleural effusion | Chest X-ray | Dense basal fluid pool |
| Ultrasound-guided aspiration | Culture for infection; pH low in empyema; glucose low in infection; cytology to identify malignancy; protein and LDH to distinguish exudate from transudate (Light's criteria) | |
| CT thorax + abdomen | Identification of underlying tumour | |
| Pulmonary embolism | d-Dimer | High negative predictive value |
| CT pulmonary angiogram | Detection of emboli; right heart strain | |
| Echocardiogram | Detection of right ventricular strain | |
| O₂ saturation or ABG | Assessment of respiratory failure | |
| Asthma | Respiratory function (peak flow diary, FEV₁/reversibility, FeNO) | Variable obstruction; reversible obstruction; often raised in asthma |
| O₂ saturation or ABG | Assessment of respiratory failure |
Where is it
Create a PDF file I can download and print
ls /home/daytona/workspace/ 2>/dev/null || mkdir -p /home/daytona/workspace/resp…
~/respiratory-notes/create_pdf.py
from reportlab.lib.pagesizes import A4
from reportlab.lib.styles import getSampleStyleSheet, ParagraphStyle
from reportlab.lib.units import cm
from reportlab.lib import colors
from reportlab.platypus import SimpleDocTemplate, Paragraph, Spacer, Table, TableStyle, HRFlowable
from reportlab.lib.enums import TA_LEFT, TA_CENTER, TA_JUSTIFY
doc = SimpleDocTemplate(
"/home/daytona/workspace/respiratory-notes/MacLeods_Respiratory_Examination_Notes.pdf",
pagesize=A4,
rightMargin=2*cm,
leftMargin=2*cm,
topMargin=2*cm,
bottomMargin=2*cm
)
styles = getSampleStyleSheet()
# Custom styles
title_style = ParagraphStyle(
'CustomTitle',
parent=styles['Title'],
fontSize=16,
textColor=colors.HexColor('#1a3a5c'),
spaceAfter=4,
spaceBefore=4,
alignment=TA_CENTER,
fontName='Helvetica-Bold'
)
subtitle_style = ParagraphStyle(
'SubTitle',
parent=styles['Normal'],
fontSize=10,
textColor=colors.HexColor('#555555'),
spaceAfter=12,
alignment=TA_CENTER,
fontName='Helvetica-Oblique'
)
h1_style = ParagraphStyle(
'H1',
parent=styles['Heading1'],
fontSize=13,
textColor=colors.white,
backColor=colors.HexColor('#1a3a5c'),
spaceBefore=14,
spaceAfter=6,
leftIndent=-10,
rightIndent=-10,
leading=18,
fontName='Helvetica-Bold'
)
h2_style = ParagraphStyle(
'H2',
parent=styles['Heading2'],
fontSize=11,
textColor=colors.white,
backColor=colors.HexColor('#c0392b'),
spaceBefore=10,
spaceAfter=4,
leftIndent=-6,
rightIndent=-6,
leading=16,
fontName='Helvetica-Bold'
)
h3_style = ParagraphStyle(
'H3',
parent=styles['Heading3'],
fontSize=10,
textColor=colors.HexColor('#1a3a5c'),
spaceBefore=8,
spaceAfter=3,
fontName='Helvetica-Bold',
borderPad=2
)
body_style = ParagraphStyle(
'Body',
parent=styles['Normal'],
fontSize=9,
leading=14,
spaceAfter=4,
alignment=TA_JUSTIFY,
fontName='Helvetica'
)
bullet_style = ParagraphStyle(
'Bullet',
parent=styles['Normal'],
fontSize=9,
leading=13,
spaceAfter=3,
leftIndent=14,
bulletIndent=4,
fontName='Helvetica'
)
sub_bullet_style = ParagraphStyle(
'SubBullet',
parent=styles['Normal'],
fontSize=9,
leading=13,
spaceAfter=2,
leftIndent=28,
bulletIndent=18,
fontName='Helvetica'
)
clinical_box_style = ParagraphStyle(
'ClinicalBox',
parent=styles['Normal'],
fontSize=9,
leading=13,
spaceAfter=3,
leftIndent=10,
rightIndent=10,
backColor=colors.HexColor('#eaf4fb'),
borderPad=4,
fontName='Helvetica'
)
note_style = ParagraphStyle(
'Note',
parent=styles['Normal'],
fontSize=8.5,
leading=12,
spaceAfter=2,
leftIndent=14,
fontName='Helvetica-Oblique',
textColor=colors.HexColor('#444444')
)
story = []
# ---- TITLE ----
story.append(Spacer(1, 0.3*cm))
story.append(Paragraph("SYSTEMIC EXAMINATION OF THE RESPIRATORY SYSTEM", title_style))
story.append(Paragraph("MacLeod's Clinical Examination — Chapter 5", subtitle_style))
story.append(HRFlowable(width="100%", thickness=2, color=colors.HexColor('#1a3a5c')))
story.append(Spacer(1, 0.4*cm))
# ==============================
# SECTION 1: INSPECTION
# ==============================
story.append(Paragraph(" 1. INSPECTION OF THE THORAX", h1_style))
story.append(Spacer(1, 0.2*cm))
story.append(Paragraph(
"Inspect the chest closely again, in case abnormalities were missed from the end of the bed.",
body_style
))
story.append(Paragraph(
"• Look carefully for any <b>scars</b> — particularly under the pectoral fold for a <b>thoracotomy scar</b>, and on the lateral and posterior chest wall for scars from <b>pleural biopsies and drains</b>.",
bullet_style
))
story.append(Paragraph(
"• In patients with a thin chest wall and increased respiratory drive (as in exacerbation of COPD), forced, rapid inspiration often causes <b>visible indrawing of the skin in the intercostal spaces</b> during inspiration, seen more easily with tangential light.",
bullet_style
))
# ==============================
# SECTION 2: PALPATION
# ==============================
story.append(Paragraph(" 2. PALPATION", h1_style))
# 2a Trachea
story.append(Paragraph("Trachea and Neck", h3_style))
story.append(Paragraph("<b>Examination Sequence (Video 2D)</b>", body_style))
story.append(Paragraph("• Support the patient's head with a pillow to facilitate relaxation of the sternocleidomastoid muscles.", bullet_style))
story.append(Paragraph("• Using a tangential light source, examine the <b>jugular venous pressure</b>.", bullet_style))
story.append(Paragraph("• Check for <b>tracheal deviation</b> by gently advancing a single finger resting in the sternal notch in the midline. The trachea should be equidistant from the two sternomastoid heads.", bullet_style))
story.append(Paragraph("• Check the <b>cricosternal distance</b> — the vertical distance between the sternal notch and the cricoid cartilage (the first prominent ridge felt above the tracheal rings). In health, <b>three average fingers</b> fit between the sternal notch and the cricoid.", bullet_style))
story.append(Paragraph("• Examine the <b>cervical lymph nodes</b> from behind with the patient sitting forward.", bullet_style))
story.append(Spacer(1, 0.2*cm))
story.append(Paragraph("<b>Clinical Significance:</b>", h3_style))
story.append(Paragraph("• Tracheal deviation <b>away</b> from the affected side → acute <b>tension pneumothorax</b>.", bullet_style))
story.append(Paragraph("• Tracheal deviation <b>towards</b> the affected side → loss of lung volume (upper lobe fibrotic scarring, collapse, lobectomy, pneumonectomy).", bullet_style))
story.append(Paragraph("• Reduction in cricosternal distance → sign of <b>hyperinflation</b> (upward displacement of sternum).", bullet_style))
story.append(Paragraph("• Rarely, systolic downward movement of the trachea → <b>aortic aneurysm</b> ('tracheal tug').", bullet_style))
story.append(Paragraph("• Palpable cervical lymph nodes → metastatic disease from lung cancer, tuberculosis, or lymphoma.", bullet_style))
# 2b Apex Beat
story.append(Paragraph("Apex Beat and Heaves", h3_style))
story.append(Paragraph("• Locate the <b>apex beat</b> — the most inferior and lateral place where the finger is lifted by the twisting systolic movement of the cardiac apex. Normally in the <b>fifth intercostal space in the mid-clavicular line</b>.", bullet_style))
story.append(Paragraph("• Palpate for a <b>right ventricular heave</b> using a straight arm, with the palm over the lower sternum.", bullet_style))
story.append(Spacer(1, 0.15*cm))
story.append(Paragraph("<b>Clinical Significance:</b>", h3_style))
story.append(Paragraph("• In <b>significant hyperinflation</b>, the apex beat may be <b>impalpable</b> because the lingula expands between the heart and the chest wall. Heart sounds are often barely audible and may be heard better by auscultating in the <b>epigastrium</b>.", bullet_style))
story.append(Paragraph("• In <b>pulmonary hypertension</b>, right ventricular heave is present and closure of the pulmonary valve may be felt — a so-called <b>palpable P2</b>.", bullet_style))
# 2c Chest Expansion
story.append(Paragraph("Chest Expansion", h3_style))
story.append(Paragraph("<b>Examination Sequence (Video 2E)</b>", body_style))
story.append(Paragraph("• Place the <b>palms over the pectoral region</b> overlying both upper lobes with elevated thumbs over the midline. Ask the patient to take a deep breath — thumbs indicate how much each hand moves outwards.", bullet_style))
story.append(Paragraph("• Cup your hands around the lower anterior chest wall overlying the lingula and right middle lobe, fingertips firmly in the <b>mid-axillary line</b>. Pull hands medially then use thumbs as pointers on full inspiration.", bullet_style))
story.append(Paragraph("• In a healthy thorax, the ribs move <b>out and up</b> with inspiration.", bullet_style))
story.append(Paragraph("• <b>Asymmetry is more important</b> than the absolute degree of expansion, which will vary between individuals.", bullet_style))
story.append(Spacer(1, 0.15*cm))
story.append(Paragraph("<b>Clinical Significance:</b>", h3_style))
story.append(Paragraph("• <b>Hoover's Sign</b>: In COPD with hyperinflation, the normal outward movement of the lower ribs on inspiration is replaced by <b>paradoxical inward movement</b>, caused by contraction of the abnormally low, flat diaphragm. May be missed if expansion is assessed only in the upper chest or from behind.", bullet_style))
story.append(Paragraph("• <b>Surgical emphysema</b>: Palpable crackling under the skin of the upper thorax, supraclavicular fossae and neck — most commonly complicates pneumothorax with chest drainage or rib fracture.", bullet_style))
story.append(Paragraph("• Examine for <b>tumour deposits</b>: Mesothelioma may grow down the track left from a pleural biopsy or chest drain and present as a firm lump at the scar site.", bullet_style))
# ==============================
# SECTION 3: PERCUSSION
# ==============================
story.append(Paragraph(" 3. PERCUSSION", h1_style))
story.append(Spacer(1, 0.2*cm))
story.append(Paragraph(
"Correctly performed, percussion should generate a <b>hollow, ringing sound</b> accompanied by a palpable resonance over air-filled lungs, but a <b>dull thud</b> lacking resonance over consolidation or fluid. Percussion is most valuable when detecting <b>asymmetry of resonance</b> between mirror image positions on the right and left sides. The absolute quality and volume of the percussed sound vary widely between individuals with differing chest wall thickness, muscularity and subcutaneous fat, and is of little value.",
body_style
))
story.append(Spacer(1, 0.15*cm))
story.append(Paragraph("<b>Examination Sequence (Videos 2F and 2G)</b>", body_style))
story.append(Paragraph("• Apply the <b>middle finger of your non-dominant hand</b> firmly to an intercostal space, parallel to the ribs, and drum the middle phalanx with the <b>flexed tip</b> of your dominant index or middle finger. The movement should come from the <b>wrist and not the elbow</b>.", bullet_style))
story.append(Paragraph("• Starting in the <b>supraclavicular fossae</b>, compare percussion at mirror image positions on right and left before moving to the next level.", bullet_style))
story.append(Paragraph("• <b>Posteriorly</b>, position the patient <b>sitting forwards with arms folded</b> in front to move the scapulae laterally. Percuss a few centimetres lateral to the spinal muscles, comparing positions the same distance from the midline on both sides.", bullet_style))
story.append(Paragraph("• Remember to percuss the <b>lateral chest wall in the mid-axillary line</b>, comparing both sides.", bullet_style))
story.append(Spacer(1, 0.15*cm))
story.append(Paragraph("<b>Clinical Significance:</b>", h3_style))
story.append(Paragraph("• In healthy people, anterior chest percussion is symmetrical except for the area immediately lateral to the lower left sternal edge — <b>'cardiac dullness'</b>. This is lost in hyperinflated patients.", bullet_style))
story.append(Paragraph("• <b>Hyper-resonance</b> (clear resonance) = usual finding over a pneumothorax.", bullet_style))
story.append(Paragraph("• Resonance on percussion together with <b>unilateral absent breath sounds</b> = indicates pneumothorax.", bullet_style))
# ==============================
# SECTION 4: AUSCULTATION
# ==============================
story.append(Paragraph(" 4. AUSCULTATION", h1_style))
story.append(Paragraph("Origin of Breath Sounds", h3_style))
story.append(Paragraph(
"The tracheobronchial tree branches <b>23 times</b> between the trachea and the alveoli, resulting in an exponential rise in the number of airways. During a maximal breath, the same vital capacity (about <b>5 L</b> of air in healthy adults) passes through each generation of airway. In the larynx and trachea, fast flow rates cause <b>turbulence with vibration of the airway wall</b>, generating sound. In the distal airway, the large combined cross-sectional area allows slow, virtually silent flow.",
body_style
))
story.append(Paragraph(
"Most of the sound heard at the chest wall originates in large central airways but is <b>muffled and deadened by overlying air-filled alveolar tissue</b>, resulting in normal ('vesicular') breath sounds. When lungs are consolidated or fibrotic, sound conduction is improved and centrally generated <b>'bronchial' breath sounds</b> may be heard clearly at the chest wall.",
body_style
))
story.append(Paragraph("Use of the Stethoscope", h3_style))
story.append(Paragraph("• Wear the stethoscope with earpieces facing <b>forwards</b> to align with your auditory canal.", bullet_style))
story.append(Paragraph("• The <b>diaphragm</b> is usually best for breath sounds due to its greater area of contact.", bullet_style))
story.append(Paragraph("• Use the <b>bell</b> in two exceptions:", bullet_style))
story.append(Paragraph(" — A <b>cachectic chest wall</b> with sunken intercostal spaces (cannot achieve flat skin contact with diaphragm).", sub_bullet_style))
story.append(Paragraph(" — A <b>hairy chest wall</b> (movement of chest hairs against diaphragm is mistaken for crackles).", sub_bullet_style))
story.append(Paragraph("<b>Examination Sequence (Videos 2H and 2I)</b>", body_style))
story.append(Paragraph("• Auscultate the <b>apices</b>, comparing right with left.", bullet_style))
story.append(Paragraph("• Ask the patient to take <b>repeated slow, deep breaths</b> in and out through their open mouth.", bullet_style))
story.append(Paragraph("• Auscultate the <b>anterior chest wall from top to bottom</b>, always comparing mirror image positions on right and left.", bullet_style))
story.append(Paragraph("• Use the same sequence of sites as for percussion.", bullet_style))
story.append(Paragraph("• Note whether breath sounds are <b>soft and muffled</b>, absent, or <b>loud and harsh (bronchial)</b>.", bullet_style))
story.append(Paragraph("• Seek and note any <b>asymmetry</b> and added sounds.", bullet_style))
story.append(Paragraph("• Auscultate the <b>lateral chest wall in the mid-axillary line</b>, comparing right with left before changing level.", bullet_style))
story.append(Paragraph("Breath Sounds — Symmetry is the Key Feature", h3_style))
story.append(Paragraph("• <b>Lobar collapse</b>: diminished expansion, dullness to percussion over collapsed lobe, reduced breath sounds and vocal resonance.", bullet_style))
story.append(Paragraph("• <b>Pneumothorax or pleural effusion</b>: breath sounds usually very quiet or absent. Distinguished by percussion — resonant with pneumothorax, dull over pleural fluid.", bullet_style))
story.append(Paragraph("Added Sounds", h3_style))
story.append(Paragraph("The three common added sounds are <b>wheezes, crackles and rubs</b>.", body_style))
story.append(Paragraph("<b>1. Wheeze</b>", body_style))
story.append(Paragraph("• A <b>musical whistling sound</b> accompanying airflow, usually originating in narrowed small airways.", bullet_style))
story.append(Paragraph("• Most commonly <b>expiratory</b> (dynamic airway narrowing on expiration), but can also occur on inspiration.", bullet_style))
story.append(Paragraph("• <b>Polyphonic wheeze</b> (multiple wheezing sounds together): common in <b>asthma, bronchitis and exacerbation of COPD</b>.", bullet_style))
story.append(Paragraph("• <b>Monophonic wheeze</b> (single, consistent with each breath, does not clear with coughing): consistent with a <b>fixed bronchial obstruction</b> — may indicate an underlying cancer partially obstructing a bronchus.", bullet_style))
story.append(Paragraph("<b>2. Crackles</b>", body_style))
story.append(Paragraph("• Brief <b>non-musical sounds</b>, most often heard on inspiration, representing sudden opening of small airways or secretions/interstitial fibrosis.", bullet_style))
story.append(Paragraph("• Gravitational crackles on the first few deep breaths in healthy people <b>clear with a deliberate cough</b> and are of no pathological significance.", bullet_style))
story.append(Paragraph("• Crackles that <b>persist after several breaths and a cough are pathological</b>.", bullet_style))
story.append(Paragraph("• Graded as:", bullet_style))
story.append(Paragraph(" — <b>'Fine'</b>: soft, multiple crackles like peeling a Velcro fastener. Characteristic of <b>interstitial pulmonary fibrosis</b>, heard at lung bases posteriorly and laterally. Also occur in pulmonary oedema and some viral pneumonias.", sub_bullet_style))
story.append(Paragraph(" — <b>'Coarse'</b>: loud, scanty crackles tending to change with each breath. Heard in <b>bronchopneumonia or bronchiectasis</b> (significant purulent secretions).", sub_bullet_style))
story.append(Paragraph("• Inspiratory crackles may also be heard over incompletely inflated lung immediately above a <b>pleural effusion</b>.", bullet_style))
story.append(Paragraph("<b>3. Pleural Rub</b>", body_style))
story.append(Paragraph("• A <b>rasping, grating sound</b> occurring with each breath, sounding superficial just under the stethoscope — like two sheets of sandpaper rubbing together.", bullet_style))
story.append(Paragraph("• Indicates <b>pleural inflammation</b>, usually due to infection or infarction of the lung, often accompanied by <b>pleuritic chest pain</b>.", bullet_style))
story.append(Paragraph("• In pneumonia, a pleural rub may disappear if a <b>parapneumonic effusion or empyema</b> develops.", bullet_style))
story.append(Paragraph("<b>Other:</b> Very rarely, a <b>clicking or crunching sound</b> synchronous with the heartbeat may indicate a <b>pneumomediastinum</b>.", bullet_style))
# ==============================
# SECTION 5: VOCAL RESONANCE
# ==============================
story.append(Paragraph(" 5. VOCAL RESONANCE", h1_style))
story.append(Spacer(1, 0.2*cm))
story.append(Paragraph(
"Confirmed by asking the patient to generate laryngeal sounds deliberately: <i>'Please say \"one, one, one\" each time I move my stethoscope'</i>. Listen on the chest wall in the same sequence of sites used for breath sounds.",
body_style
))
story.append(Paragraph("• <b>Muffled and deadened</b> over healthy lung.", bullet_style))
story.append(Paragraph("• <b>Heard loudly and clearly</b> over consolidated or fibrotic scarred lung.", bullet_style))
story.append(Paragraph("• <b>Absent or greatly diminished</b> over pneumothorax and pleural effusion.", bullet_style))
story.append(Paragraph(
"<b>'Whispering pectoriloquy':</b> Whispered speech is muffled to silence by normal lung but may be heard over consolidated or scarred lung. Used to confirm changes in sound conduction.",
bullet_style
))
# ==============================
# SECTION 6: INTERPRETATION
# ==============================
story.append(Paragraph(" 6. INTERPRETATION OF FINDINGS", h1_style))
story.append(Spacer(1, 0.2*cm))
story.append(Paragraph(
"Review your findings and collate the positive features. Consistent groups of signs may even be diagnostic — for example, <b>unilateral absent breath sounds, resonant percussion, and tracheal deviation to the opposite side</b> in a collapsed patient indicate a likely <b>tension pneumothorax</b>.",
body_style
))
story.append(Spacer(1, 0.3*cm))
story.append(Paragraph("Box 5.7 — Categories of Respiratory Disease and Associated Features", h3_style))
table_data = [
[
Paragraph('<b>Category</b>', ParagraphStyle('th', fontName='Helvetica-Bold', fontSize=8.5, textColor=colors.white)),
Paragraph('<b>Suggestive History</b>', ParagraphStyle('th', fontName='Helvetica-Bold', fontSize=8.5, textColor=colors.white)),
Paragraph('<b>Suggestive Examination</b>', ParagraphStyle('th', fontName='Helvetica-Bold', fontSize=8.5, textColor=colors.white)),
],
['Acute bronchitis', 'Cough, sputum, wheeze, acute-on-chronic dyspnoea', 'Polyphonic wheeze'],
['Exacerbation of COPD', "Cough, mucopurulent sputum, ankle swelling ('cor pulmonale'), headache (hypercapnia)", 'Hyperinflation, quiet breath sounds, polyphonic wheeze, flapping tremor (CO\u2082 retention), ankle oedema'],
['Pneumonia', 'Fever, rigors, pleuritic pain, rusty sputum, loss of appetite', 'If lobar: dull percussion, bronchial breathing, increased vocal resonance'],
['Malignancy', 'Insidious onset, weight loss, cough, haemoptysis, persisting pain', 'Cervical lymphadenopathy, finger clubbing, signs of lobar/lung collapse \u00b1 effusion'],
['Pulmonary fibrosis', 'Progressive dyspnoea, cough', 'Tachypnoea, finger clubbing, central cyanosis, inspiratory fine crackles at bases'],
['Pleural effusion', 'Progressive dyspnoea', 'Unilateral basal dullness and reduced breath sounds'],
['Pulmonary embolism (large)', 'Sudden severe dyspnoea', 'Normal breath sounds'],
['Pulmonary embolism (medium)', 'Episodes of pleuritic pain, haemoptysis', 'Pleural rub, crackles if infarct'],
['Pulmonary embolism (multiple small)', 'Progressive dyspnoea', 'Raised JVP, residual volume heave, loud P2'],
['Asthma', 'Atopy, hay fever, pet ownership, variable wheeze, disturbance of sleep', 'Polyphonic expiratory wheeze, eczema'],
]
cell_style = ParagraphStyle('cell', fontName='Helvetica', fontSize=8, leading=11)
def make_table_cells(data):
result = []
for i, row in enumerate(data):
if i == 0:
result.append(row)
else:
result.append([Paragraph(str(cell), cell_style) for cell in row])
return result
table_data_formatted = make_table_cells(table_data)
t = Table(table_data_formatted, colWidths=[3.8*cm, 6.5*cm, 6.5*cm], repeatRows=1)
t.setStyle(TableStyle([
('BACKGROUND', (0,0), (-1,0), colors.HexColor('#1a3a5c')),
('TEXTCOLOR', (0,0), (-1,0), colors.white),
('FONTNAME', (0,0), (-1,0), 'Helvetica-Bold'),
('FONTSIZE', (0,0), (-1,0), 8.5),
('ROWBACKGROUNDS', (0,1), (-1,-1), [colors.HexColor('#eaf4fb'), colors.white]),
('GRID', (0,0), (-1,-1), 0.4, colors.HexColor('#aaaaaa')),
('VALIGN', (0,0), (-1,-1), 'TOP'),
('TOPPADDING', (0,0), (-1,-1), 4),
('BOTTOMPADDING', (0,0), (-1,-1), 4),
('LEFTPADDING', (0,0), (-1,-1), 4),
('RIGHTPADDING', (0,0), (-1,-1), 4),
]))
story.append(t)
# ==============================
# SECTION 7: INVESTIGATIONS
# ==============================
story.append(Paragraph(" 7. INVESTIGATIONS", h1_style))
story.append(Spacer(1, 0.15*cm))
story.append(Paragraph(
"Selecting the relevant investigation depends on the clinical problem revealed on history and examination. In respiratory disease, <b>imaging of the lungs is fundamental</b>, but <b>respiratory function testing</b> is equally important to distinguish obstructive disease from the restrictive pattern.",
body_style
))
story.append(Spacer(1, 0.25*cm))
story.append(Paragraph("Box 5.8 — Selecting Investigations for Different Respiratory Presentations", h3_style))
inv_data = [
[
Paragraph('<b>Problem</b>', ParagraphStyle('th2', fontName='Helvetica-Bold', fontSize=8.5, textColor=colors.white)),
Paragraph('<b>Appropriate Initial Investigations</b>', ParagraphStyle('th2', fontName='Helvetica-Bold', fontSize=8.5, textColor=colors.white)),
Paragraph('<b>Diagnostic Value</b>', ParagraphStyle('th2', fontName='Helvetica-Bold', fontSize=8.5, textColor=colors.white)),
],
['Infection\n(bronchitis, COPD, pneumonia)',
'Chest X-ray\nO\u2082 saturation, ABG\nSputum/blood culture\nWCC, CRP',
'Consolidation in pneumonia\nAssessment of respiratory failure\nIdentify causal infection\nDegree of inflammation'],
['Malignancy',
'Chest X-ray\nCT thorax + abdomen\nBronchoscopy if central\nEBUS\nCT-guided biopsy if peripheral\nRespiratory function',
'Identification of lesion\nTumour stage\nDiagnostic pathology\nAllows lymph node sampling\nDiagnostic pathology\nFitness for surgery/radiotherapy'],
['Pulmonary fibrosis /\nInterstitial lung disease',
'Chest X-ray\nHRCT thorax\nRespiratory function\nExercise test (6 min walk)\nAutoantibodies',
'Bi-basal reticular shadows\nExtent and pattern of disease\nQuantification; restrictive pattern; impaired gas transfer\nFunctional capacity\nAssociated connective tissue disease'],
['Pleural effusion',
'Chest X-ray\nUltrasound-guided aspiration\nCT thorax + abdomen',
'Dense basal fluid pool\npH (empyema), glucose, cytology, protein/LDH (Light\'s criteria)\nIdentification of underlying tumour'],
['Pulmonary embolism',
'd-Dimer\nCT pulmonary angiogram\nEchocardiogram\nO\u2082 saturation or ABG',
'High negative predictive value\nDetection of emboli; right heart strain\nDetection of right ventricular strain\nAssessment of respiratory failure'],
['Asthma',
'Peak flow diary\nFEV\u2081/reversibility\nFeNO\nO\u2082 saturation or ABG',
'Variable obstruction\nReversible obstruction\nOften raised in asthma\nAssessment of respiratory failure'],
]
def make_inv_cells(data):
cell_s = ParagraphStyle('icell', fontName='Helvetica', fontSize=8, leading=11)
result = []
for i, row in enumerate(data):
if i == 0:
result.append(row)
else:
result.append([Paragraph(str(cell).replace('\n', '<br/>'), cell_s) for cell in row])
return result
inv_data_fmt = make_inv_cells(inv_data)
t2 = Table(inv_data_fmt, colWidths=[4.0*cm, 6.0*cm, 6.8*cm], repeatRows=1)
t2.setStyle(TableStyle([
('BACKGROUND', (0,0), (-1,0), colors.HexColor('#1a3a5c')),
('TEXTCOLOR', (0,0), (-1,0), colors.white),
('FONTNAME', (0,0), (-1,0), 'Helvetica-Bold'),
('FONTSIZE', (0,0), (-1,0), 8.5),
('ROWBACKGROUNDS', (0,1), (-1,-1), [colors.HexColor('#eaf4fb'), colors.white]),
('GRID', (0,0), (-1,-1), 0.4, colors.HexColor('#aaaaaa')),
('VALIGN', (0,0), (-1,-1), 'TOP'),
('TOPPADDING', (0,0), (-1,-1), 4),
('BOTTOMPADDING', (0,0), (-1,-1), 4),
('LEFTPADDING', (0,0), (-1,-1), 4),
('RIGHTPADDING', (0,0), (-1,-1), 4),
]))
story.append(t2)
story.append(Spacer(1, 0.5*cm))
story.append(HRFlowable(width="100%", thickness=1, color=colors.HexColor('#1a3a5c')))
story.append(Spacer(1, 0.15*cm))
story.append(Paragraph("Source: MacLeod's Clinical Examination, Chapter 5 — The Respiratory System", subtitle_style))
doc.build(story)
print("PDF created successfully!")
cd /home/daytona/workspace/respiratory-notes && python create_pdf.py
MacLeods Respiratory Examination Notes
PDF Document · PDF
Where is it
MacLeods Respiratory Examination Notes
PDF Document · PDF