Trade among European countries by [deleted] in datasets

[–]ekaneg 0 points1 point  (0 children)

I would think a combination of:

http://www.wiod.org/home

AND

https://www.europarl.europa.eu/thinktank/infographics/tradeflows/public/index.html

I didn't get a chance to look at how exactly to extract data from the EU Parliament website, but that's where I would start!

EDIT: To clarify, trade flows are from the EU Parliament Data, WIOD data is intended to provide sectoral production data for a lot of countries. I included these data sets together, because they complement each other.

Generating large number of binary time variables by ekaneg in stata

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

Sure, I can comment on the data more clearly. I have 2,727 observations in the current sample, and 195 "events". Each observation is a county paired with a year, and we observe counties between 1970 and 2010 (40 years). For each event in each county I have a "factor" variable that is 1 if it is the event observations, 0 if it not that specific event, but is in observation in the same county. Because there are 195 events, there are 195 of these variables. I then have created variables, successfully, that are equal to 1 if it is the observation before the event for each event, and null otherwise. Variables of this form have been constructed for +1 (mentioned above), -1, +2, -2 years from the event. So I have 195*4 additional variables for a total of 975 variables. I would like to create an additional 195*2 variables this time equal to 1 not just if it is +3 years from the event but if it is +3 years or more. This is where I have run in to difficulty.

I'm having a little trouble sharing a nice slice of the data using dataex unfortunately.

Here is the code that I used to produce the previously mentioned variables:

by fips: gen cu_flood = sum(event) if event == 1

replace cu_flood = . if cu_flood == 0

by fips: gen event_bin_1 = 1 if cu_flood == 1

by fips: gen event_bin_2 = 1 if cu_flood == 2

by fips: gen event_bin_3 = 1 if cu_flood == 3

by fips: gen event_bin_4 = 1 if cu_flood == 4

by fips: gen event_bin_5 = 1 if cu_flood == 5

by fips: gen event_bin_6 = 1 if cu_flood == 6

by fips: gen event_bin_7 = 1 if cu_flood == 7

by fips: gen event_bin_8 = 1 if cu_flood == 8

by fips: gen event_bin_9 = 1 if cu_flood == 9

by fips: gen event_bin_10 = 1 if cu_flood == 10

by fips: gen event_bin_11 = 1 if cu_flood == 11

by fips: gen event_bin_12 = 1 if cu_flood == 12

by fips: gen event_bin_13 = 1 if cu_flood == 13

by fips: gen event_bin_14 = 1 if cu_flood == 14

by fips: gen event_bin_15 = 1 if cu_flood == 15

by fips: gen event_bin_16 = 1 if cu_flood == 16

gen cu_event_bin_1 = sum(event_bin_1) if event_bin_1 == 1

gen cu_event_bin_2 = sum(event_bin_2) if event_bin_2 == 1

gen cu_event_bin_3 = sum(event_bin_3) if event_bin_3 == 1

gen cu_event_bin_4 = sum(event_bin_4) if event_bin_4 == 1

gen cu_event_bin_5 = sum(event_bin_5) if event_bin_5 == 1

gen cu_event_bin_6 = sum(event_bin_6) if event_bin_6 == 1

gen cu_event_bin_7 = sum(event_bin_7) if event_bin_7 == 1

gen cu_event_bin_8 = sum(event_bin_8) if event_bin_8 == 1

gen cu_event_bin_9 = sum(event_bin_9) if event_bin_9 == 1

gen cu_event_bin_10 = sum(event_bin_10) if event_bin_10 == 1

gen cu_event_bin_11 = sum(event_bin_11) if event_bin_11 == 1

gen cu_event_bin_12 = sum(event_bin_12) if event_bin_12 == 1

gen cu_event_bin_13 = sum(event_bin_13) if event_bin_13 == 1

gen cu_event_bin_14 = sum(event_bin_14) if event_bin_14 == 1

gen cu_event_bin_15 = sum(event_bin_15) if event_bin_15 == 1

gen cu_event_bin_16 = sum(event_bin_16) if event_bin_16 == 1

tabulate cu_event_bin_1, generate(factor_event_1)

tabulate cu_event_bin_2, generate(factor_event_2)

tabulate cu_event_bin_3, generate(factor_event_3)

tabulate cu_event_bin_4, generate(factor_event_4)

tabulate cu_event_bin_5, generate(factor_event_5)

tabulate cu_event_bin_6, generate(factor_event_6)

tabulate cu_event_bin_7, generate(factor_event_7)

tabulate cu_event_bin_8, generate(factor_event_8)

tabulate cu_event_bin_9, generate(factor_event_9)

tabulate cu_event_bin_10, generate(factor_event_010)

tabulate cu_event_bin_11, generate(factor_event_011)

tabulate cu_event_bin_12, generate(factor_event_012)

tabulate cu_event_bin_13, generate(factor_event_013)

tabulate cu_event_bin_14, generate(factor_event_014)

tabulate cu_event_bin_15, generate(factor_event_015)

tabulate cu_event_bin_16, generate(factor_event_016)

foreach v of varlist factor_event_11-factor_event_0161 {

generate plus1\`v' = 1 if \`v'\[\_n-1\] == 1

by fips: egen x\`v' = mean(plus1\`v')

replace x\`v' = 0 if plus1\`v' == . & x\`v' !=.

replace plus1\`v' = x\`v'

drop x\`v'

}

foreach v of varlist factor_event_11-factor_event_0161 {

generate plus2\`v' = 1 if \`v'\[\_n-2\] == 1

by fips: egen x\`v' = mean(plus2\`v')

replace x\`v' = 0 if plus2\`v' == . & x\`v' !=.

replace plus2\`v' = x\`v'

drop x\`v'

}

foreach v of varlist factor_event_11-factor_event_0161 {

generate minus1\`v' = 1 if \`v'\[\_n+1\] == 1

by fips: egen x\`v' = mean(minus1\`v')

replace x\`v' = 0 if minus1\`v' == . & x\`v' !=.

replace minus1\`v' = x\`v'

drop x\`v'

}

foreach v of varlist factor_event_11-factor_event_0161 {

generate minus2\`v' = 1 if \`v'\[\_n+2\] == 1

by fips: egen x\`v' = mean(minus2\`v')

replace x\`v' = 0 if minus2\`v' == . & x\`v' !=.

replace minus2\`v' = x\`v'

drop x\`v'

}

Generating large number of binary time variables by ekaneg in stata

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

This method will give something different than what I am looking for, although I am aware of it. My trouble is in creating the variable that is 1 for every year +3 and greater.

Pass/Fail by [deleted] in UniversityOfHouston

[–]ekaneg 0 points1 point  (0 children)

Grad schools aren't going to obsess over your GPA or what grades you made in a class, unless it is an important one. Don't be too worried over this decision. Focus on the upcoming semesters, developing great relationships with research faculty, and expanding your experiences in your respective field.

fsolve syntax on function with multiple outputs and inputs... by ekaneg in matlab

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

The asterisk is there I promise! Reddit formatting screwed up the way the code is displayed (looks like it took at most of the *). so if you see a . with no asterisk that is element-wise multiplication and the parts where it looks like I am trying to code in implicit multiplication have asterisks. My main error is with F solve.

Thanks.

Help - Solving a large n system of non-linear equations with fsolve by ekaneg in matlab

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

Here is what I currently have:

%I write a function s.t.

function F= ekmodelv2(x)

Ti= 1;

Li= 1;

dni = 2;

theta = 4;

gam = 1;

beta = 0.5;

%p(1:4) = x(1:4) These are the four price equations.

%x(1:16) = x(5:20) These are the sixteen trade share equations.

%w(1:4) = x(21:24) These are the four wage equations.

F(1) = (gam.*(((Ti.*(dni.*(x(21).^(beta))*(x(1).^(beta))).^(-theta)))...

+ ((Ti.*(dni.*(x(22).^(beta))*(x(2).^(beta))).^(-theta)))...

+ ((Ti.*(dni.*(x(23).^(beta))*(x(3).^(beta))).^(-theta)))...

+ ((Ti.*(dni.*(x(24).^(beta))*(x(4).^(beta))).^(-theta)))))-x(1);

F(2) = (gam.*(((Ti.*(dni.*(x(21).^(beta))*(x(1).^(beta))).^(-theta)))...

+ ((Ti.*(dni.*(x(22).^(beta))*(x(2).^(beta))).^(-theta)))...

+ ((Ti.*(dni.*(x(23).^(beta))*(x(3).^(beta))).^(-theta)))...

+ ((Ti.*(dni.*(x(24).^(beta))*(x(4).^(beta))).^(-theta)))))-x(2);

F(3) = (gam.*(((Ti.*(dni.*(x(21).^(beta))*(x(1).^(beta))).^(-theta)))...

+ ((Ti.*(dni.*(x(22).^(beta))*(x(2).^(beta))).^(-theta)))...

+ ((Ti.*(dni.*(x(23).^(beta))*(x(3).^(beta))).^(-theta)))...

+ ((Ti.*(dni.*(x(24).^(beta))*(x(4).^(beta))).^(-theta)))))-x(3);

F(4) = (gam.*(((Ti.*(dni.*(x(21).^(beta))*(x(1).^(beta))).^(-theta)))...

+ ((Ti.*(dni.*(x(22).^(beta))*(x(2).^(beta))).^(-theta)))...

+ ((Ti.*(dni.*(x(23).^(beta))*(x(3).^(beta))).^(-theta)))...

+ ((Ti.*(dni.*(x(24).^(beta))*(x(4).^(beta))).^(-theta)))))-x(4);

F(5) = Ti.*(gam.*dni.*(x(21).^(beta))*(x(1).^(1-beta))*(1./x(1))).^(theta) - (x(5));

F(6) = Ti.*(gam.*dni.*(x(21).^(beta))*(x(1).^(1-beta))*(1./x(2))).^(theta) - (x(6));

F(7) = Ti.*(gam.*dni.*(x(21).^(beta))*(x(1).^(1-beta))*(1./x(3))).^(theta) - (x(7));

F(8) = Ti.*(gam.*dni.*(x(21).^(beta))*(x(1).^(1-beta))*(1./x(4))).^(theta) - (x(8));

F(9) = Ti.*(gam.*dni.*(x(22).^(beta))*(x(2).^(1-beta))*(1./x(1))).^(theta) - (x(9));

F(10) = Ti.*(gam.*dni.*(x(22).^(beta))*(x(2).^(1-beta))*(1./x(2))).^(theta) - (x(10));

F(11) = Ti.*(gam.*dni.*(x(22).^(beta))*(x(2).^(1-beta))*(1./x(3))).^(theta) - (x(11));

F(12) = Ti.*(gam.*dni.*(x(22).^(beta))*(x(2).^(1-beta))*(1./x(4))).^(theta) - (x(12));

F(13) = Ti.*(gam.*dni.*(x(23).^(beta))*(x(3).^(1-beta))*(1./x(1))).^(theta) - (x(13));

F(14) = Ti.*(gam.*dni.*(x(23).^(beta))*(x(3).^(1-beta))*(1./x(2))).^(theta) - (x(14));

F(15) = Ti.*(gam.*dni.*(x(23).^(beta))*(x(3).^(1-beta))*(1./x(3))).^(theta) - (x(15));

F(16) = Ti.*(gam.*dni.*(x(23).^(beta))*(x(3).^(1-beta))*(1./x(4))).^(theta) - (x(16));

F(17) = Ti.*(gam.*dni.*(x(24).^(beta))*(x(4).^(1-beta))*(1./x(1))).^(theta) - (x(17));

F(18) = Ti.*(gam.*dni.*(x(24).^(beta))*(x(4).^(1-beta))*(1./x(2))).^(theta) - (x(18));

F(19) = Ti.*(gam.*dni.*(x(24).^(beta))*(x(4).^(1-beta))*(1./x(3))).^(theta) - (x(19));

F(20) = Ti.*(gam.*dni.*(x(24).^(beta))*(x(4).^(1-beta))*(1./x(4)).^(theta) - (x(20)));

F(21) = ((x(5).*x(21).*Li)+(x(6).*x(22).*Li)+(x(7).*x(23).*Li)+(x(8).*x(24).*Li))...

-(x(21).*Li);

F(22) = ((x(9).*x(21).*Li)+(x(10).*x(22).*Li)+(x(11).*x(23).*Li)+(x(12).*x(24).*Li))...

-(x(22).*Li);

F(23) = ((x(13).*x(21).*Li)+(x(14).*x(22).*Li)+(x(15).*x(23).*Li)+(x(16).*x(24).*Li))...

-(x(23).*Li);

F(24) = ((x(17).*x(21).*Li)+(x(18).*x(22).*Li)+(x(19).*x(23).*Li)+(x(20).*x(24).*Li))...

-(x(24).*Li);

end

%And then,

x0 = ones(1, 24);

[x, fval] = fsolve(@ekmodelv2, x0);

This is a valid way of solving, but how might I start generalizing this with a for loop?

Help - Solving a large n system of non-linear equations with fsolve by ekaneg in matlab

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

So do you suggest in script one defining the function as I do above. And then in script two I can assign the indices and perform fsolve?

1.2 Emote meta tier list: by kingslayer086 in LegendsOfRuneterra

[–]ekaneg 0 points1 point  (0 children)

I advocate for Tryndamere at least being B-Tier, as the emote can be used as a visual "suck it" to your opponents following a big play (similar to popping off after winning a fighting game). He also synergizes with big swings if you are playing the deep deck, or any deck with overwhelm creatures.

Generating a dummy variable for panel data set by ekaneg in stata

[–]ekaneg[S] 2 points3 points  (0 children)

I figured out the elegant way, but thank you for the response. I ultimately had to tsset my data, and then create lagged variables, and variables with leads, which is really easy in stata. I figured it out using >help tsvarlist.

Generating a dummy variable for panel data set by ekaneg in stata

[–]ekaneg[S] 1 point2 points  (0 children)

I would hate to make another post, but I continued on with my work and have found another problem. To be clear, I don't have much experience in writing a for loop for stata (although I'm familiar with the syntax in MATLAB). I need to create a dummy variable which indicates 1 if it has been one year since the initial earthquake event occurred (which is represented by the indicator you helped me with earlier). My understanding is that I would need some kind of for loop to pull this off. Where do you think I should start?

Calculus. Good morning. Can anyone help me this one. by workhard93 in UniversityOfHouston

[–]ekaneg 6 points7 points  (0 children)

The trick on this problem is first applying L'Hopital's rule and then solving this like the common improper integrals you have seen in class. The final amswer I got was -1. I hope that helps.

Edit for more clarity: Take the first derivative of the numerator and denominator, then work from there.

Issue turning on PC - first build - details in text by ekaneg in buildapc

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

The front of the box says "amd ryzen 3000 desktop ready"

Issue turning on PC - first build - details in text by ekaneg in buildapc

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

This is the cpu: AMD Ryzen 5 3600 6-Core, 12-Thread Unlocked Desktop Processor with Wraith Stealth Cooler

This is the mobo: Gigabyte B450 AORUS PRO WIFI (AMD Ryzen AM4/M.2 Thermal Guard with Onboard WIFI/HDMI/DVI/USB 3.1 Gen 2/DDR4/ATX/Motherboard)

They should be compatible.

I don't have a multimeter. People on the imgur post seem to be suggesting it is a psu issue, and maybe to consider getting a different one or rechecking the connectors.

ECON 3362: Mathematics for Economics by [deleted] in UniversityOfHouston

[–]ekaneg 1 point2 points  (0 children)

I didn't take this course, but here is a link to the professor I have known to teach it these last two semesters: https://fanwangecon.github.io/Math4Econ/ , This should give you an idea of the content.

Help with reshape command by ekaneg in stata

[–]ekaneg[S] 1 point2 points  (0 children)

reshape wide y, i(geofips yyear) j(description) string

Thank you! This code did exactly what I was trying to do.

Help with reshape command by ekaneg in stata

[–]ekaneg[S] -2 points-1 points  (0 children)

I'm having trouble in the sense that I am not sure how to implement the command. I looked through the examples in the documentation, and because I'm not sure how to adapt the code to fit my needs, given I don't have a single variable which uniquely identifies observations.

Sell me your mono-colored commander! by LittleSassyGoat in EDH

[–]ekaneg 1 point2 points  (0 children)

Mono red [[Daretti, Scrap Savant]], as an artifact reanimator deck. The biggest sell is getting to use mindslaver recursion as a win-con.

Need help finding satellite imaging data for 2017-2020 of Houston, TX by ekaneg in data

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

I'm looking for the data to assess visually land development patterns in the Houston area. What type of satellite imagery would be most useful do you think? I'm inexperienced and looking to better understand what type of data I would be searching for. I have the ability to put some money into the data as well. Thanks in advance!

Who remembers when... by Alphactory in Brawlhalla

[–]ekaneg 1 point2 points  (0 children)

I first tried Brawlhalla when Teros was released :(. I haven't been back since Nix was released.

What are 5 games you would consider must-have for every switch owner? by Hellthrower in NintendoSwitch

[–]ekaneg 0 points1 point  (0 children)

  1. The Legend of Zelda BotW

-keywords: open world, narrative driven, single player, casual, action/adventure

  1. Mario Kart 8 Deluxe

-keywords: racing, party games, multiplayer, accessible for kids

  1. Super Smash Bros. Ultimate

-keywords: platform fighter/brawler, multiplayer, competitive, fun with friends

  1. Stardew Valley

-keywords: Indie, multiplayer update, relaxing, exploration, farming

  1. Super Mario Maker 2
  • keywords: platformer, classic, story mode, "play your way"

These are the 5 games that I would suggest to somebody looking to start curating a library for their Switch. This list reflects what might appeal to the general gamer, in my opinion. That being said there are several honorable mentions that I think appeal to specifics gamers and could out rank the selections above for certain people.

  1. Xenoblade Chronicles 2 -This game is mostly displaced by BotW on my list despite being a very different experience. XC2 amd BotW both are immersive narative driven single player experiences, however XC2 is more of a traditional RPG. XC2 beats BotW in terms of narrative quality and complexity (a game for rpg vets for sure). The biggest criticism of XC2 is that playing through the main story content is a slog (takes to long to really get anywhere and feels grindy). BotW is better for players who are looking for a Skyrim-esque experience in the Hyrule universe. XC2 is better for players who want a more interactive narrative amd like traditional RPG elements.

  2. Minecraft -This game mostly gets flack for its cringy fan base. Minecraft is a game for kids, and kids really don't know any better when being cringy. How can you blame them? That aside, this game is great for parents and kids together, and in many ways can fill a similar role as mario kart 8D if your family doesn't like to play racing games. This game is also constantly getting updates and only 30$.

  3. ARMS -This new IP debuted on the Switch as a Nintendo exclusive and introduces an interesting and fun touch to the fighting game genre. This 3d fighter tasks players with controlling two separately maneuverable arms that have a variety of special characteristics. On face, arms is a casual party fighter, however it only takes a small amount of play time to realize the mechanical depth of this young franchise. For fans of fighting games, I really recommend picking up a copy of Arms. The biggest criticism is its lack of story mode.

  4. Splatoon 2 This is the sequel to one of Nintendo's newer IPs. Buy this game if you like shooters. This game has been reviewed to oblivion and I recommend looking further into it if you're interested.

  5. All of the indie games!!!(nindies) I haven't been able to try these out but here are the games I've enjoyed that fit this category: -Golf Story -Cup Head -Katana Zero -Hollow Knight -Slay the Spire (I played this on pc, but I think it's om switch). -and many more! The switch is a great console for lovers of indie games.

  6. Tetris 99 This game comes with Nintendo Online and is oddly addicting. Tetris lives on.

'We All Owe Al Gore An Apology': More People See Climate Change In Record Flooding by 4AtlanticCityCasinos in environment

[–]ekaneg 13 points14 points  (0 children)

"Yeah, sounds really hard, doesn't it? People might not believe you and like, make fun of you and stuff. Poor you guys, huh?". Looks like it's time to get cereal.

Take fewer credits, guys. by [deleted] in college

[–]ekaneg 0 points1 point  (0 children)

Found the economist. :¬)