playing with parameters

This commit is contained in:
Frederico 2024-12-16 22:07:03 +01:00
parent 906bb97619
commit cd5c6772ab

View File

@ -9,7 +9,7 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 1,
"metadata": {},
"outputs": [],
"source": [
@ -26,7 +26,7 @@
},
{
"cell_type": "code",
"execution_count": 27,
"execution_count": 2,
"metadata": {},
"outputs": [],
"source": [
@ -35,18 +35,19 @@
},
{
"cell_type": "code",
"execution_count": 28,
"execution_count": 3,
"metadata": {},
"outputs": [],
"source": [
"params = SimulationParameters(\n",
" num_blocks=int(days * 24 * 60 * 60 / 12), # number of blocks in \"days\",\n",
" demand_sizes=[50, 1000, 2000], # very low, normal, very high demand\n",
" demand_probabilities=[0.05, 0.9, 0.05], # they must sum to 1\n",
" fee_cap_range=(-0.05, 0.3), \n",
" demand_sizes=[0, 50, 1000, 2000], # very low, normal, very high demand\n",
" demand_probabilities=[0.02, 0.06, 0.86, 0.06], # they must sum to 1\n",
" fee_cap_range=(0.05, 0.1), # in percentage, mean and std deviation\n",
" max_tip_pct=0.1,\n",
" scale_block_size_limits=(0.0, 0.2),\n",
" probability_stop_below_gas_limit=0.5\n",
" scale_block_size_limits=(0.05, 0.1),\n",
" probability_stop_below_gas_limit=0.5,\n",
" purge_after=2\n",
")"
]
},
@ -65,7 +66,9 @@
"metadata": {},
"outputs": [],
"source": [
"df_stats_merged[[\"price_EIP\", \"price_StableFee\"]].plot()"
"df_stats_merged[[\"price_EIP\", \"price_StableFee\"]].plot(\n",
" title=\"EIP-1559 vs StableFee price\",\n",
")"
]
},
{
@ -86,6 +89,15 @@
"df_stats_merged[[\"tot_paid_EIP\", \"tot_paid_StableFee\"]].plot()"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"df_stats_merged[[\"demand_size_EIP\"]].plot.bar()"
]
},
{
"cell_type": "code",
"execution_count": null,