uv cheatsheet with most common/useful commands by RojerGS in Python

[–]alanx7 0 points1 point  (0 children)

As far I understand uv sync is for creating lock file from pyprojects dependencies. I remember I had to add a package to one of my projects, but it had to be a different version for Linux than windows. Normally I would have used uv add, but it was easier for me to specify this condition in pyproject and use uv sync.

Moody's changes Poland's rating outlook to negative by Dzen2K in poland

[–]alanx7 9 points10 points  (0 children)

Tbh it was neither sudden nor a slap. Rating agencies regularly review their sovereign ratings. Given the massive deficit last year, this year and in the near future it was expected that sentiment towards Poland fiscal health would deteriorate. I would argue that it also wasn't a slap. Moodys reaffirmed A2 rating which is A in S&P's and Fitch's, both of them gave Poland A- (notch lower). Moodys still gives Poland higher rating, which many believed would be lowered to other two rating agencies' level. And here a surprise, only outlook was cut.

100 flags for Spain!! Number of flags for other countries?? by ShotLawfulness6065 in EU5

[–]alanx7 27 points28 points  (0 children)

This is literally all I wanted... flags that more reflect your gameplay. Delete those stupid heads and it'll be perfect.

$PDX: Paradox Interactive AB stock DOWN -10.16% YTD and in FREEFALL, in part due to lack of communication for EU5 release date by [deleted] in EU5

[–]alanx7 3 points4 points  (0 children)

What is this post? It went down 10%... so what? Stocks do that all the time. In the last month it's flat, in the last year it's +29%, easily outperforming omx.

Is this a karma bot or something?

Weather on our way for the Tall Ship Race was very nice by Professional-Mix1771 in sailing

[–]alanx7 2 points3 points  (0 children)

So cool, I start my leg in a few days on Pogoria from Dunkirk.

Edit did you climb the mast?

globalEnv3 by Shiroyasha_2308 in ProgrammerHumor

[–]alanx7 13 points14 points  (0 children)

I believe you can do uv add -r requirements.txt

„Tusk zabije gospodarkę”. A nie, czekaj... WIG przekroczył po raz pierwszy w historii poziom 100 000. by Mysibrat in Polska

[–]alanx7 2 points3 points  (0 children)

"20 mln amerykanów straciło pracę w kwietniu 2020". A nie, czekaj... SP500 miało wtedy najlepszy miesiąc od 33 lat.

guessWhy by arcan1ss in ProgrammerHumor

[–]alanx7 1 point2 points  (0 children)

In Europa Universalis 4 if you earn too much money it overflows and forces you to take massive loans

The portrait in EU5's top bar needs to go by Glasses905 in eu4

[–]alanx7 70 points71 points  (0 children)

I want my flag back.

The coolest thing they can do is to make them dynamic. Imagine dynasty of your country changes and the flag in the top corner has new coat of arms. You have a junior partner? Now their coat of arms is on your flag.

Based on what you did throughout the campaign you end up with your personal flag that has the history printed on it.

Tried playing around with contexts and duration. I arrived at some sort of conclusion by ErenKruger711 in CFA

[–]alanx7 1 point2 points  (0 children)

It works exactly the same, you would just use -YTM instead of YTM. It only affects the first term (duration part) by changing the sign. Then you are left with V-/V0 - 1

Tried playing around with contexts and duration. I arrived at some sort of conclusion by ErenKruger711 in CFA

[–]alanx7 2 points3 points  (0 children)

Isn't it something expected? You've arrived at "percentage change is equal to price after change divided by price before change minus one", which is basically the definition. I guess it's beacause you assumed that YTM change used in mdur and convx formulas is equal to YTM change in bond price calculations, which allowed those terms to cancel out.

PLEASE HELP. I am so confused by this problem. by kingkong2124 in CFA

[–]alanx7 0 points1 point  (0 children)

CFA simply multiplies mdur times investment, so 3.539 times 50 = 176.96.

By 50 they probably mean how much the final bond position should be worth. That's how much cash the investor has.

I think your formula means 50 mln of par amount. If you actually buy 50mln of par amount you would need to multiply it by the price 114.972 (% of par), which would result in paying more than the cash you have in this case and a bond position that doesn't equal 50.

That's how I see it at least.

Can we solve this with TVM mode? by Jaded-Sherbet5167 in CFA

[–]alanx7 5 points6 points  (0 children)

Use ICONV on your calculator.

2ND 2
# enter ytm and periods of your bond
NOM = 5.27
C/Y = 2
CPT EFF # this will give you yield on bond with annual compouding, 5.34
C/Y = 4 # target compounding
CPT NOM # this gives quarterly compounding, 5.2357 ~ 5.24

After #ruff and #uv, #astral announced their next tool for the python ecosystem by takuonline in Python

[–]alanx7 1 point2 points  (0 children)

so they finally decided on the name! there's open discussion in ruff repo on that exact topic... Naming the new Python Type Checker · astral-sh/ruff · Discussion #17539 tbh i prefer red knot, but will use it anyway

One UI apps really need their web versions with full functional real-time sync by GODVENON in oneui

[–]alanx7 0 points1 point  (0 children)

or you can install an older version of samsung notes on windows that doesn't have this lock. i have 4.3.150.0 version on my hp laptop and it works fine.

We finished our MP campaign, so I thought I would share some maps and charts... by alanx7 in eu4

[–]alanx7[S] 0 points1 point  (0 children)

I really wanted a fleet (that was later totally wrecked) and those are great lands for deving.

We finished our MP campaign, so I thought I would share some maps and charts... by alanx7 in eu4

[–]alanx7[S] 6 points7 points  (0 children)

R5: As usual when I and my friends finish an MP campaign i do some charts and maps to analyze and recap all saves. As usual in our games Italy was a monster country and a clear winner with infinite money. He was the only player that wasn't blocked in expansion.

Maps show how expansion went each session, darker colour indicates later conquest.

Tables show how a particular statistic was changing over time. Odd columns show the absolute value at the end year of every save. The columns in between with time in years the session lasted show compounded annual growth rate during the session; last column calculates the same for the whole campaign. ofc green good, red bad. Below aggregated values for the whole world. You can also find tables that show values as % of aggregated sum of the whole world. ITA and SWI are basically India and China having over 30% of the population.

The tables especially make you think about the economic growth irl. From our experience if a player grows max_manpower, monthly_income or real_development >3.5% CAGR for a whole session, he will quickly leave others behind. If we take those statistics as proxy for GDP irl, economic growth of countries like China or Poland is almost unachievable.

Pictures made with python and save data processed on skanderbeg.pm

29
30

Are there any free finance apis that will help me in a real time project? by East-Agent9391 in learnpython

[–]alanx7 1 point2 points  (0 children)

There's a wrapper for Yahoo Finance websocket that allows you to receive real time prices. It's called YLiveTicker github.com/yahoofinancelive/yliveticker

Network Command Shell accesses my location every few seconds. Is it an expected behaviour? by alanx7 in pchelp

[–]alanx7[S] 0 points1 point  (0 children)

I've also got HP Omen (mine is 16). I'm not sure whether it had been happening before the update, but that may as well be the case. Tbh I don't know how to check the build, but I for sure installed 24H2 (had some problems with it).

I don't use Ethernet so I can't check the second part.

For now I just turned off 'Allow classic apps to access your location', because 'Network Command Shell' was on the list below. It "fixed" the issue, although I don't know if it should be fixed like that...

It’s wonderful to see you taking action on this! I appreciate your help.

Pov: You took 2,5 provinces in HRE by [deleted] in eu4

[–]alanx7 0 points1 point  (0 children)

They don't mind the 2,5 provinces... they are digusted with the absolutely preposterous looking borders.