panelbox 0.2.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (90) hide show
  1. panelbox/__init__.py +67 -0
  2. panelbox/__version__.py +14 -0
  3. panelbox/cli/__init__.py +0 -0
  4. panelbox/cli/{commands}/__init__.py +0 -0
  5. panelbox/core/__init__.py +0 -0
  6. panelbox/core/base_model.py +164 -0
  7. panelbox/core/formula_parser.py +318 -0
  8. panelbox/core/panel_data.py +387 -0
  9. panelbox/core/results.py +366 -0
  10. panelbox/datasets/__init__.py +0 -0
  11. panelbox/datasets/{data}/__init__.py +0 -0
  12. panelbox/gmm/__init__.py +65 -0
  13. panelbox/gmm/difference_gmm.py +645 -0
  14. panelbox/gmm/estimator.py +562 -0
  15. panelbox/gmm/instruments.py +580 -0
  16. panelbox/gmm/results.py +550 -0
  17. panelbox/gmm/system_gmm.py +621 -0
  18. panelbox/gmm/tests.py +535 -0
  19. panelbox/models/__init__.py +11 -0
  20. panelbox/models/dynamic/__init__.py +0 -0
  21. panelbox/models/iv/__init__.py +0 -0
  22. panelbox/models/static/__init__.py +13 -0
  23. panelbox/models/static/fixed_effects.py +516 -0
  24. panelbox/models/static/pooled_ols.py +298 -0
  25. panelbox/models/static/random_effects.py +512 -0
  26. panelbox/report/__init__.py +61 -0
  27. panelbox/report/asset_manager.py +410 -0
  28. panelbox/report/css_manager.py +472 -0
  29. panelbox/report/exporters/__init__.py +15 -0
  30. panelbox/report/exporters/html_exporter.py +440 -0
  31. panelbox/report/exporters/latex_exporter.py +510 -0
  32. panelbox/report/exporters/markdown_exporter.py +446 -0
  33. panelbox/report/renderers/__init__.py +11 -0
  34. panelbox/report/renderers/static/__init__.py +0 -0
  35. panelbox/report/renderers/static_validation_renderer.py +341 -0
  36. panelbox/report/report_manager.py +502 -0
  37. panelbox/report/template_manager.py +337 -0
  38. panelbox/report/transformers/__init__.py +0 -0
  39. panelbox/report/transformers/static/__init__.py +0 -0
  40. panelbox/report/validation_transformer.py +449 -0
  41. panelbox/standard_errors/__init__.py +0 -0
  42. panelbox/templates/__init__.py +0 -0
  43. panelbox/templates/assets/css/base_styles.css +382 -0
  44. panelbox/templates/assets/css/report_components.css +747 -0
  45. panelbox/templates/assets/js/tab-navigation.js +161 -0
  46. panelbox/templates/assets/js/utils.js +276 -0
  47. panelbox/templates/common/footer.html +24 -0
  48. panelbox/templates/common/header.html +44 -0
  49. panelbox/templates/common/meta.html +5 -0
  50. panelbox/templates/validation/interactive/index.html +272 -0
  51. panelbox/templates/validation/interactive/partials/charts.html +58 -0
  52. panelbox/templates/validation/interactive/partials/methodology.html +201 -0
  53. panelbox/templates/validation/interactive/partials/overview.html +146 -0
  54. panelbox/templates/validation/interactive/partials/recommendations.html +101 -0
  55. panelbox/templates/validation/interactive/partials/test_results.html +231 -0
  56. panelbox/utils/__init__.py +0 -0
  57. panelbox/utils/formatting.py +172 -0
  58. panelbox/utils/matrix_ops.py +233 -0
  59. panelbox/utils/statistical.py +173 -0
  60. panelbox/validation/__init__.py +58 -0
  61. panelbox/validation/base.py +175 -0
  62. panelbox/validation/cointegration/__init__.py +0 -0
  63. panelbox/validation/cross_sectional_dependence/__init__.py +13 -0
  64. panelbox/validation/cross_sectional_dependence/breusch_pagan_lm.py +222 -0
  65. panelbox/validation/cross_sectional_dependence/frees.py +297 -0
  66. panelbox/validation/cross_sectional_dependence/pesaran_cd.py +188 -0
  67. panelbox/validation/heteroskedasticity/__init__.py +13 -0
  68. panelbox/validation/heteroskedasticity/breusch_pagan.py +222 -0
  69. panelbox/validation/heteroskedasticity/modified_wald.py +172 -0
  70. panelbox/validation/heteroskedasticity/white.py +208 -0
  71. panelbox/validation/instruments/__init__.py +0 -0
  72. panelbox/validation/robustness/__init__.py +0 -0
  73. panelbox/validation/serial_correlation/__init__.py +13 -0
  74. panelbox/validation/serial_correlation/baltagi_wu.py +220 -0
  75. panelbox/validation/serial_correlation/breusch_godfrey.py +260 -0
  76. panelbox/validation/serial_correlation/wooldridge_ar.py +200 -0
  77. panelbox/validation/specification/__init__.py +16 -0
  78. panelbox/validation/specification/chow.py +273 -0
  79. panelbox/validation/specification/hausman.py +264 -0
  80. panelbox/validation/specification/mundlak.py +331 -0
  81. panelbox/validation/specification/reset.py +273 -0
  82. panelbox/validation/unit_root/__init__.py +0 -0
  83. panelbox/validation/validation_report.py +257 -0
  84. panelbox/validation/validation_suite.py +401 -0
  85. panelbox-0.2.0.dist-info/METADATA +337 -0
  86. panelbox-0.2.0.dist-info/RECORD +90 -0
  87. panelbox-0.2.0.dist-info/WHEEL +5 -0
  88. panelbox-0.2.0.dist-info/entry_points.txt +2 -0
  89. panelbox-0.2.0.dist-info/licenses/LICENSE +21 -0
  90. panelbox-0.2.0.dist-info/top_level.txt +1 -0
@@ -0,0 +1,382 @@
1
+ /**
2
+ * PanelBox Reports - Base Styles (Layer 1)
3
+ * ==========================================
4
+ *
5
+ * Foundation CSS with design tokens, reset, and utilities.
6
+ * This layer is shared across ALL report types.
7
+ *
8
+ * Size: ~10-12 KB
9
+ * Version: 1.0.0
10
+ */
11
+
12
+ /* ============================================
13
+ DESIGN TOKENS
14
+ ============================================ */
15
+
16
+ :root {
17
+ /* Primary Colors */
18
+ --primary: #2563eb;
19
+ --primary-dark: #1e40af;
20
+ --primary-light: #60a5fa;
21
+ --primary-lighter: #dbeafe;
22
+
23
+ /* Semantic Colors */
24
+ --success: #10b981;
25
+ --success-light: #d1fae5;
26
+ --warning: #f59e0b;
27
+ --warning-light: #fef3c7;
28
+ --danger: #ef4444;
29
+ --danger-light: #fee2e2;
30
+ --info: #3b82f6;
31
+ --info-light: #dbeafe;
32
+
33
+ /* Test Result Colors */
34
+ --reject: #ef4444;
35
+ --reject-bg: #fee2e2;
36
+ --accept: #10b981;
37
+ --accept-bg: #d1fae5;
38
+ --inconclusive: #f59e0b;
39
+ --inconclusive-bg: #fef3c7;
40
+
41
+ /* Neutral Grays */
42
+ --gray-50: #f9fafb;
43
+ --gray-100: #f3f4f6;
44
+ --gray-200: #e5e7eb;
45
+ --gray-300: #d1d5db;
46
+ --gray-400: #9ca3af;
47
+ --gray-500: #6b7280;
48
+ --gray-600: #4b5563;
49
+ --gray-700: #374151;
50
+ --gray-800: #1f2937;
51
+ --gray-900: #111827;
52
+
53
+ /* Typography */
54
+ --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
55
+ "Helvetica Neue", Arial, sans-serif;
56
+ --font-mono: "Fira Code", "SF Mono", "Monaco", "Cascadia Code",
57
+ "Roboto Mono", "Courier New", monospace;
58
+
59
+ --text-xs: 0.75rem; /* 12px */
60
+ --text-sm: 0.875rem; /* 14px */
61
+ --text-base: 1rem; /* 16px */
62
+ --text-lg: 1.125rem; /* 18px */
63
+ --text-xl: 1.25rem; /* 20px */
64
+ --text-2xl: 1.5rem; /* 24px */
65
+ --text-3xl: 1.875rem; /* 30px */
66
+ --text-4xl: 2.25rem; /* 36px */
67
+
68
+ --font-normal: 400;
69
+ --font-medium: 500;
70
+ --font-semibold: 600;
71
+ --font-bold: 700;
72
+
73
+ --line-height-tight: 1.25;
74
+ --line-height-normal: 1.5;
75
+ --line-height-relaxed: 1.75;
76
+
77
+ /* Spacing Scale */
78
+ --space-0: 0;
79
+ --space-1: 0.25rem; /* 4px */
80
+ --space-2: 0.5rem; /* 8px */
81
+ --space-3: 0.75rem; /* 12px */
82
+ --space-4: 1rem; /* 16px */
83
+ --space-5: 1.25rem; /* 20px */
84
+ --space-6: 1.5rem; /* 24px */
85
+ --space-8: 2rem; /* 32px */
86
+ --space-10: 2.5rem; /* 40px */
87
+ --space-12: 3rem; /* 48px */
88
+ --space-16: 4rem; /* 64px */
89
+ --space-20: 5rem; /* 80px */
90
+
91
+ /* Border Radius */
92
+ --radius-sm: 0.125rem; /* 2px */
93
+ --radius: 0.25rem; /* 4px */
94
+ --radius-md: 0.375rem; /* 6px */
95
+ --radius-lg: 0.5rem; /* 8px */
96
+ --radius-xl: 0.75rem; /* 12px */
97
+ --radius-2xl: 1rem; /* 16px */
98
+ --radius-full: 9999px;
99
+
100
+ /* Shadows */
101
+ --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
102
+ --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
103
+ --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
104
+ --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
105
+ --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
106
+ --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
107
+
108
+ /* Transitions */
109
+ --transition-fast: 150ms ease;
110
+ --transition-base: 200ms ease;
111
+ --transition-slow: 300ms ease;
112
+
113
+ /* Z-index Scale */
114
+ --z-base: 0;
115
+ --z-dropdown: 1000;
116
+ --z-sticky: 1100;
117
+ --z-fixed: 1200;
118
+ --z-modal-backdrop: 1300;
119
+ --z-modal: 1400;
120
+ --z-popover: 1500;
121
+ --z-tooltip: 1600;
122
+
123
+ /* Breakpoints (for reference, not used directly in CSS) */
124
+ --breakpoint-sm: 640px;
125
+ --breakpoint-md: 768px;
126
+ --breakpoint-lg: 1024px;
127
+ --breakpoint-xl: 1280px;
128
+ }
129
+
130
+ /* ============================================
131
+ CSS RESET & NORMALIZATION
132
+ ============================================ */
133
+
134
+ *,
135
+ *::before,
136
+ *::after {
137
+ box-sizing: border-box;
138
+ margin: 0;
139
+ padding: 0;
140
+ }
141
+
142
+ html {
143
+ -webkit-font-smoothing: antialiased;
144
+ -moz-osx-font-smoothing: grayscale;
145
+ text-rendering: optimizeLegibility;
146
+ font-size: 16px;
147
+ line-height: var(--line-height-normal);
148
+ }
149
+
150
+ body {
151
+ font-family: var(--font-sans);
152
+ font-size: var(--text-base);
153
+ color: var(--gray-900);
154
+ background-color: var(--gray-50);
155
+ min-height: 100vh;
156
+ }
157
+
158
+ /* Typography Reset */
159
+ h1, h2, h3, h4, h5, h6 {
160
+ font-weight: var(--font-semibold);
161
+ line-height: var(--line-height-tight);
162
+ color: var(--gray-900);
163
+ }
164
+
165
+ p {
166
+ margin-bottom: var(--space-4);
167
+ }
168
+
169
+ a {
170
+ color: var(--primary);
171
+ text-decoration: none;
172
+ transition: color var(--transition-fast);
173
+ }
174
+
175
+ a:hover {
176
+ color: var(--primary-dark);
177
+ text-decoration: underline;
178
+ }
179
+
180
+ /* Lists */
181
+ ul, ol {
182
+ list-style: none;
183
+ }
184
+
185
+ /* Tables */
186
+ table {
187
+ border-collapse: collapse;
188
+ width: 100%;
189
+ }
190
+
191
+ /* Forms */
192
+ button, input, select, textarea {
193
+ font-family: inherit;
194
+ font-size: inherit;
195
+ line-height: inherit;
196
+ }
197
+
198
+ button {
199
+ cursor: pointer;
200
+ border: none;
201
+ background: none;
202
+ }
203
+
204
+ /* Images */
205
+ img {
206
+ max-width: 100%;
207
+ height: auto;
208
+ display: block;
209
+ }
210
+
211
+ /* Code */
212
+ code, pre {
213
+ font-family: var(--font-mono);
214
+ font-size: 0.875em;
215
+ }
216
+
217
+ /* ============================================
218
+ UTILITY CLASSES
219
+ ============================================ */
220
+
221
+ /* Display */
222
+ .block { display: block !important; }
223
+ .inline-block { display: inline-block !important; }
224
+ .inline { display: inline !important; }
225
+ .flex { display: flex !important; }
226
+ .inline-flex { display: inline-flex !important; }
227
+ .grid { display: grid !important; }
228
+ .hidden { display: none !important; }
229
+
230
+ /* Flexbox */
231
+ .flex-row { flex-direction: row !important; }
232
+ .flex-col { flex-direction: column !important; }
233
+ .flex-wrap { flex-wrap: wrap !important; }
234
+ .items-start { align-items: flex-start !important; }
235
+ .items-center { align-items: center !important; }
236
+ .items-end { align-items: flex-end !important; }
237
+ .justify-start { justify-content: flex-start !important; }
238
+ .justify-center { justify-content: center !important; }
239
+ .justify-end { justify-content: flex-end !important; }
240
+ .justify-between { justify-content: space-between !important; }
241
+ .gap-1 { gap: var(--space-1) !important; }
242
+ .gap-2 { gap: var(--space-2) !important; }
243
+ .gap-3 { gap: var(--space-3) !important; }
244
+ .gap-4 { gap: var(--space-4) !important; }
245
+ .gap-6 { gap: var(--space-6) !important; }
246
+ .gap-8 { gap: var(--space-8) !important; }
247
+
248
+ /* Spacing - Margin */
249
+ .m-0 { margin: 0 !important; }
250
+ .m-1 { margin: var(--space-1) !important; }
251
+ .m-2 { margin: var(--space-2) !important; }
252
+ .m-3 { margin: var(--space-3) !important; }
253
+ .m-4 { margin: var(--space-4) !important; }
254
+ .m-6 { margin: var(--space-6) !important; }
255
+ .m-8 { margin: var(--space-8) !important; }
256
+
257
+ .mt-0 { margin-top: 0 !important; }
258
+ .mt-2 { margin-top: var(--space-2) !important; }
259
+ .mt-4 { margin-top: var(--space-4) !important; }
260
+ .mt-6 { margin-top: var(--space-6) !important; }
261
+ .mt-8 { margin-top: var(--space-8) !important; }
262
+
263
+ .mb-0 { margin-bottom: 0 !important; }
264
+ .mb-2 { margin-bottom: var(--space-2) !important; }
265
+ .mb-4 { margin-bottom: var(--space-4) !important; }
266
+ .mb-6 { margin-bottom: var(--space-6) !important; }
267
+ .mb-8 { margin-bottom: var(--space-8) !important; }
268
+
269
+ .ml-auto { margin-left: auto !important; }
270
+ .mr-auto { margin-right: auto !important; }
271
+ .mx-auto { margin-left: auto !important; margin-right: auto !important; }
272
+
273
+ /* Spacing - Padding */
274
+ .p-0 { padding: 0 !important; }
275
+ .p-1 { padding: var(--space-1) !important; }
276
+ .p-2 { padding: var(--space-2) !important; }
277
+ .p-3 { padding: var(--space-3) !important; }
278
+ .p-4 { padding: var(--space-4) !important; }
279
+ .p-6 { padding: var(--space-6) !important; }
280
+ .p-8 { padding: var(--space-8) !important; }
281
+
282
+ .px-2 { padding-left: var(--space-2) !important; padding-right: var(--space-2) !important; }
283
+ .px-4 { padding-left: var(--space-4) !important; padding-right: var(--space-4) !important; }
284
+ .px-6 { padding-left: var(--space-6) !important; padding-right: var(--space-6) !important; }
285
+ .px-8 { padding-left: var(--space-8) !important; padding-right: var(--space-8) !important; }
286
+
287
+ .py-2 { padding-top: var(--space-2) !important; padding-bottom: var(--space-2) !important; }
288
+ .py-4 { padding-top: var(--space-4) !important; padding-bottom: var(--space-4) !important; }
289
+ .py-6 { padding-top: var(--space-6) !important; padding-bottom: var(--space-6) !important; }
290
+ .py-8 { padding-top: var(--space-8) !important; padding-bottom: var(--space-8) !important; }
291
+
292
+ /* Typography */
293
+ .text-xs { font-size: var(--text-xs) !important; }
294
+ .text-sm { font-size: var(--text-sm) !important; }
295
+ .text-base { font-size: var(--text-base) !important; }
296
+ .text-lg { font-size: var(--text-lg) !important; }
297
+ .text-xl { font-size: var(--text-xl) !important; }
298
+ .text-2xl { font-size: var(--text-2xl) !important; }
299
+ .text-3xl { font-size: var(--text-3xl) !important; }
300
+ .text-4xl { font-size: var(--text-4xl) !important; }
301
+
302
+ .font-normal { font-weight: var(--font-normal) !important; }
303
+ .font-medium { font-weight: var(--font-medium) !important; }
304
+ .font-semibold { font-weight: var(--font-semibold) !important; }
305
+ .font-bold { font-weight: var(--font-bold) !important; }
306
+
307
+ .text-left { text-align: left !important; }
308
+ .text-center { text-align: center !important; }
309
+ .text-right { text-align: right !important; }
310
+
311
+ .uppercase { text-transform: uppercase !important; }
312
+ .capitalize { text-transform: capitalize !important; }
313
+
314
+ /* Text Colors */
315
+ .text-primary { color: var(--primary) !important; }
316
+ .text-success { color: var(--success) !important; }
317
+ .text-warning { color: var(--warning) !important; }
318
+ .text-danger { color: var(--danger) !important; }
319
+ .text-gray-500 { color: var(--gray-500) !important; }
320
+ .text-gray-600 { color: var(--gray-600) !important; }
321
+ .text-gray-700 { color: var(--gray-700) !important; }
322
+ .text-gray-900 { color: var(--gray-900) !important; }
323
+
324
+ /* Background Colors */
325
+ .bg-white { background-color: #ffffff !important; }
326
+ .bg-gray-50 { background-color: var(--gray-50) !important; }
327
+ .bg-gray-100 { background-color: var(--gray-100) !important; }
328
+ .bg-primary { background-color: var(--primary) !important; }
329
+ .bg-success { background-color: var(--success) !important; }
330
+ .bg-warning { background-color: var(--warning) !important; }
331
+ .bg-danger { background-color: var(--danger) !important; }
332
+
333
+ /* Border */
334
+ .border { border: 1px solid var(--gray-200) !important; }
335
+ .border-t { border-top: 1px solid var(--gray-200) !important; }
336
+ .border-b { border-bottom: 1px solid var(--gray-200) !important; }
337
+ .border-l { border-left: 1px solid var(--gray-200) !important; }
338
+ .border-r { border-right: 1px solid var(--gray-200) !important; }
339
+
340
+ .rounded { border-radius: var(--radius) !important; }
341
+ .rounded-lg { border-radius: var(--radius-lg) !important; }
342
+ .rounded-xl { border-radius: var(--radius-xl) !important; }
343
+ .rounded-full { border-radius: var(--radius-full) !important; }
344
+
345
+ /* Shadow */
346
+ .shadow { box-shadow: var(--shadow) !important; }
347
+ .shadow-md { box-shadow: var(--shadow-md) !important; }
348
+ .shadow-lg { box-shadow: var(--shadow-lg) !important; }
349
+
350
+ /* Width */
351
+ .w-full { width: 100% !important; }
352
+ .w-auto { width: auto !important; }
353
+ .max-w-screen-sm { max-width: 640px !important; }
354
+ .max-w-screen-md { max-width: 768px !important; }
355
+ .max-w-screen-lg { max-width: 1024px !important; }
356
+ .max-w-screen-xl { max-width: 1280px !important; }
357
+
358
+ /* Overflow */
359
+ .overflow-auto { overflow: auto !important; }
360
+ .overflow-hidden { overflow: hidden !important; }
361
+ .overflow-x-auto { overflow-x: auto !important; }
362
+
363
+ /* Cursor */
364
+ .cursor-pointer { cursor: pointer !important; }
365
+ .cursor-not-allowed { cursor: not-allowed !important; }
366
+
367
+ /* Opacity */
368
+ .opacity-0 { opacity: 0 !important; }
369
+ .opacity-50 { opacity: 0.5 !important; }
370
+ .opacity-75 { opacity: 0.75 !important; }
371
+ .opacity-100 { opacity: 1 !important; }
372
+
373
+ /* Transitions */
374
+ .transition { transition: all var(--transition-base) !important; }
375
+ .transition-fast { transition: all var(--transition-fast) !important; }
376
+
377
+ /* Print */
378
+ @media print {
379
+ .no-print {
380
+ display: none !important;
381
+ }
382
+ }