Give answers of these questions for MD medicine final year examination,add diagrams and flowcharts and kindly prepare notes and make PDF
heart failure fifth pillar treatment SGLT2 inhibitors biomarkers BNP NT-proBNP 2024
gene therapy types indications CRISPR CAR-T cell therapy medical review 2024
EUS endoscopic ultrasound gastroenterology indications clinical uses 2024
human microbiota neurological disorders gut-brain axis Parkinson Alzheimer review 2024
mitochondrial diseases classification clinical features treatment 2024 medicine
mkdir -p /home/daytona/workspace/md-medicine-notes && ls /home/daytona/workspace/
Give answers of these questions for MD medicine final year examination,add diagrams and flowcharts and kindly prepare notes and make notes
glycemic variability definition clinical significance CGM management diabetes 2024
neurotherapeutic technology Parkinson disease DBS gene therapy stem cell 2024
mitochondrial diseases MELAS MERRF Leigh syndrome clinical features diagnosis treatment review
obesity newer treatment modalities tirzepatide semaglutide bariatric metabolic surgery 2024
mkdir -p /home/daytona/workspace/md-medicine-notes && echo "Directory ready"
Give answers of these questions for MD medicine final year examination,add diagrams and add flow charts
heart failure fifth pillar SGLT2 inhibitor treatment 2024 four pillars HFrEF guidelines
protein folding disorders chaperones Alzheimer Parkinson Huntington amyloid prion 2024 review
human microbiota composition gut brain axis neurological disorders 2024 review mechanisms
Parkinson disease neurotherapeutic technology deep brain stimulation focused ultrasound optogenetics 2024
mkdir -p /home/daytona/workspace/md-medicine-notes && python3 << 'PYEOF' from reportlab.lib.pagesizes import A4 from reportlab.lib.styles import getSampleStyleSheet, ParagraphStyle from reportlab.lib.units import cm, mm from reportlab.lib.colors import (HexColor, white, black, Color, lightblue, lightgrey, darkblue) from reportlab.platypus import (SimpleDocTemplate, Paragraph, Spacer, Table, TableStyle, PageBreak, HRFlowable, KeepTogether) from reportlab.platypus.flowables import Flowable from reportlab.lib.enums import TA_CENTER, TA_LEFT, TA_JUSTIFY from reportlab.graphics.shapes import Drawing, Rect, String, Line, Polygon, Circle, Arrow from reportlab.graphics import renderPDF from reportlab.graphics.shapes import (Drawing, Rect, String, Line, Polygon, Circle, Group) from reportlab.platypus import Image import io # Color palette DARK_BLUE = HexColor('#1a3a5c') MED_BLUE = HexColor('#2563a8') LIGHT_BLUE = HexColor('#d0e8f8') TEAL = HexColor('#0e7490') GREEN = HexColor('#166534') LIGHT_GREEN = HexColor('#dcfce7') RED = HexColor('#991b1b') LIGHT_RED = HexColor('#fee2e2') ORANGE = HexColor('#c2410c') LIGHT_ORANGE = HexColor('#ffedd5') PURPLE = HexColor('#6d28d9') LIGHT_PURPLE = HexColor('#ede9fe') YELLOW = HexColor('#854d0e') LIGHT_YELLOW = HexColor('#fef9c3') GREY_BG = HexColor('#f1f5f9') DARK_TEXT = HexColor('#1e293b') SILVER = HexColor('#e2e8f0') BOX_BLUE = HexColor('#eff6ff') BOX_BORDER = HexColor('#bfdbfe') W, H = A4 PAGE_W = W - 3*cm styles = getSampleStyleSheet() def make_style(name, parent='Normal', **kw): s = ParagraphStyle(name, parent=styles[parent], **kw) return s # Define all styles title_style = make_style('MyTitle', fontSize=22, textColor=white, alignment=TA_CENTER, fontName='Helvetica-Bold', spaceAfter=6, spaceBefore=4) sub_title = make_style('SubTitle', fontSize=13, textColor=DARK_BLUE, alignment=TA_CENTER, fontName='Helvetica-Bold', spaceAfter=10) q_head = make_style('QHead', fontSize=14, textColor=white, fontName='Helvetica-Bold', spaceAfter=4, spaceBefore=14) section_head = make_style('SecHead', fontSize=12, textColor=DARK_BLUE, fontName='Helvetica-Bold', spaceAfter=4, spaceBefore=8) body_style = make_style('Body', fontSize=10, textColor=DARK_TEXT, leading=15, alignment=TA_JUSTIFY, spaceAfter=4) bullet_style = make_style('Bullet', fontSize=10, textColor=DARK_TEXT, leading=14, leftIndent=14, bulletIndent=4, spaceAfter=2) small_style = make_style('Small', fontSize=8.5, textColor=DARK_TEXT, leading=12) box_head = make_style('BoxHead', fontSize=10.5, textColor=DARK_BLUE, fontName='Helvetica-Bold', spaceAfter=2) note_style = make_style('Note', fontSize=9, textColor=HexColor('#4a5568'), leading=13, leftIndent=10, spaceAfter=2) # ---------- Helper flowables ---------- class ColorRect(Flowable): def __init__(self, width, height, color, radius=4): super().__init__() self.width = width; self.height = height self.color = color; self.radius = radius def draw(self): self.canv.setFillColor(self.color) self.canv.roundRect(0, 0, self.width, self.height, self.radius, stroke=0, fill=1) def section_banner(text, bg=DARK_BLUE, text_color=white, width=PAGE_W): data = [[Paragraph(text, make_style('_b', fontSize=13, textColor=text_color, fontName='Helvetica-Bold'))]] t = Table(data, colWidths=[width]) t.setStyle(TableStyle([ ('BACKGROUND', (0,0), (-1,-1), bg), ('TOPPADDING', (0,0), (-1,-1), 7), ('BOTTOMPADDING', (0,0), (-1,-1), 7), ('LEFTPADDING', (0,0), (-1,-1), 10), ('RIGHTPADDING', (0,0), (-1,-1), 10), ('ROUNDEDCORNERS', [5]), ])) return t def info_box(title, content_paragraphs, bg=BOX_BLUE, border=BOX_BORDER, width=PAGE_W): rows = [[Paragraph(f'<b>{title}</b>', make_style('_bh', fontSize=10.5, textColor=MED_BLUE, fontName='Helvetica-Bold'))]] for p in content_paragraphs: rows.append([p]) t = Table(rows, colWidths=[width]) t.setStyle(TableStyle([ ('BACKGROUND', (0,0), (-1,-1), bg), ('BOX', (0,0), (-1,-1), 1, border), ('TOPPADDING', (0,0), (-1,-1), 5), ('BOTTOMPADDING', (0,0), (-1,-1), 5), ('LEFTPADDING', (0,0), (-1,-1), 8), ('RIGHTPADDING', (0,0), (-1,-1), 8), ('ROWBACKGROUNDS', (0,0), (0,0), [HexColor('#dbeafe')]), ])) return t def two_col_table(left_items, right_items, header_l='', header_r='', width=PAGE_W): col = width/2 - 3 rows = [] if header_l: rows.append([Paragraph(f'<b>{header_l}</b>', make_style('_th', fontSize=10, textColor=white, fontName='Helvetica-Bold')), Paragraph(f'<b>{header_r}</b>', make_style('_th2', fontSize=10, textColor=white, fontName='Helvetica-Bold'))]) for l, r in zip(left_items, right_items): rows.append([Paragraph(f'• {l}', bullet_style), Paragraph(f'• {r}', bullet_style)]) t = Table(rows, colWidths=[col, col]) st = [('GRID', (0,0), (-1,-1), 0.5, SILVER), ('TOPPADDING', (0,0), (-1,-1), 4), ('BOTTOMPADDING', (0,0), (-1,-1), 4), ('LEFTPADDING', (0,0), (-1,-1), 6), ('RIGHTPADDING', (0,0), (-1,-1), 6), ('VALIGN', (0,0), (-1,-1), 'TOP'), ('ROWBACKGROUNDS', (0,0), (-1,-1), [white, GREY_BG]), ] if header_l: st += [('BACKGROUND', (0,0), (1,0), DARK_BLUE), ('ROWBACKGROUNDS', (0,1), (-1,-1), [white, GREY_BG])] t.setStyle(TableStyle(st)) return t def make_flowchart_simple(steps, colors=None, width=PAGE_W): """Vertical flowchart with arrows between boxes.""" if colors is None: colors = [MED_BLUE] * len(steps) box_w = width * 0.75 box_h = 26 arrow_h = 14 total_h = len(steps) * (box_h + arrow_h) d = Drawing(width, total_h + 10) x0 = (width - box_w) / 2 y = total_h - box_h + 5 for i, (step, col) in enumerate(zip(steps, colors)): # Draw box d.add(Rect(x0, y, box_w, box_h, fillColor=col, strokeColor=white, strokeWidth=1, rx=5, ry=5)) d.add(String(x0 + box_w/2, y + box_h/2 - 5, step, textAnchor='middle', fontSize=9, fillColor=white, fontName='Helvetica-Bold')) # Arrow down if i < len(steps) - 1: ax = x0 + box_w/2 ay_top = y d.add(Line(ax, ay_top, ax, ay_top - arrow_h + 5, strokeColor=DARK_BLUE, strokeWidth=1.5)) # arrowhead d.add(Polygon([ax-5, ay_top-arrow_h+8, ax+5, ay_top-arrow_h+8, ax, ay_top-arrow_h+2], fillColor=DARK_BLUE, strokeColor=DARK_BLUE)) y -= (box_h + arrow_h) return d def horizontal_flow(steps, colors=None, width=PAGE_W): n = len(steps) box_w = (width - 10) / n - 12 box_h = 38 arrow_w = 12 total_w = n * box_w + (n-1) * arrow_w + 10 d = Drawing(total_w, box_h + 10) if colors is None: colors = [MED_BLUE] * n x = 5 for i, (step, col) in enumerate(zip(steps, colors)): d.add(Rect(x, 5, box_w, box_h, fillColor=col, strokeColor=white, strokeWidth=1, rx=4, ry=4)) lines = step.split('\n') for li, ln in enumerate(lines[:3]): d.add(String(x + box_w/2, 5 + box_h - 12 - li*11, ln, textAnchor='middle', fontSize=8, fillColor=white, fontName='Helvetica-Bold')) x += box_w if i < n-1: mid_y = 5 + box_h/2 d.add(Line(x, mid_y, x+arrow_w-4, mid_y, strokeColor=DARK_BLUE, strokeWidth=1.5)) d.add(Polygon([x+arrow_w-4, mid_y-4, x+arrow_w-4, mid_y+4, x+arrow_w, mid_y], fillColor=DARK_BLUE, strokeColor=DARK_BLUE)) x += arrow_w return d print("Helper functions defined. Proceeding to build content...") print("OK") PYEOF echo "Script test: $?"