<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Arthur Caldas on Medium]]></title>
        <description><![CDATA[Stories by Arthur Caldas on Medium]]></description>
        <link>https://medium.com/@arthurmlcaldass?source=rss-6c4414fd7a7------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*DERXhwyf9f4-4BeWm6M52w.jpeg</url>
            <title>Stories by Arthur Caldas on Medium</title>
            <link>https://medium.com/@arthurmlcaldass?source=rss-6c4414fd7a7------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 28 Nov 2026 16:55:37 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@arthurmlcaldass/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Beating soccer odds using Machine Learning — Project Walkthrough]]></title>
            <link>https://medium.com/analytics-vidhya/beating-soccer-odds-using-machine-learning-project-walkthrough-a1c3445b285a?source=rss-6c4414fd7a7------2</link>
            <guid isPermaLink="false">https://medium.com/p/a1c3445b285a</guid>
            <category><![CDATA[soccer-prediction]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[soccer]]></category>
            <category><![CDATA[python]]></category>
            <dc:creator><![CDATA[Arthur Caldas]]></dc:creator>
            <pubDate>Fri, 18 Jun 2021 13:50:40 GMT</pubDate>
            <atom:updated>2021-06-30T09:02:50.479Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ZJL5rneLzlyrv0gWlwepEQ.jpeg" /><figcaption>Photo by <a href="https://unsplash.com/@jesusance">Thomas Serer</a> on <a href="https://unsplash.com/">Unsplash</a></figcaption></figure><h3>Beating soccer odds using Machine Learning — Project Walkthrough</h3><p>It isn&#39;t news to anyone that predicting soccer matches is a tough task. After all, how can you predict something so unpredictable as soccer? Based on this challenge, I decided to use my Data Science knowledge to create a project in order to not only have satisfying prediction results, but also beat the bookmakers obtaining profit in my predictions.</p><h3>Web Scraping</h3><p>First, I had to obtain as much data as I could find from soccer matches. Fortunately, <a href="https://www.oddsportal.com/">the odds portal</a> had available information about matches of almost 16 years worth of Premier League seasons.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/969/1*wRSSri_HeTKMgVlGxCV60A.jpeg" /><figcaption>Source: <a href="https://www.oddsportal.com/soccer/england/premier-league-2020-2021/results/">Oddsportal</a></figcaption></figure><p>I got the data from the website using two Python libraries for Web Scraping, <a href="https://www.crummy.com/software/BeautifulSoup/bs4/doc/"><strong>BeautifulSoup</strong></a> and <a href="https://www.selenium.dev/docs/"><strong>Selenium</strong></a>. Basically, I did the whole scraping structure in BeautifulSoup and used Selenium to click on the next page, since this library allows you to perform actions on web pages just like a human would.</p><p>After the scraping, I had obtained data from 6077 Premier League matches from season 2005/2006 to 2020/2021 with 7 columns of information:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/860/1*mVOLmDTO0C0MoNdJ4dqQUg.png" /><figcaption>Source: <a href="https://github.com/Caldass/pl-matches-predictor">My Github code</a></figcaption></figure><ul><li><strong>season</strong>: Match’s season.</li><li><strong>date</strong>: Date of the match.</li><li><strong>match_name</strong>: “Home team vs Away team” string.</li><li><strong>result</strong>: Match result.</li><li><strong>h_odd</strong>: Home team&#39;s winning odd.</li><li><strong>d_odd</strong>: Draw odd.</li><li><strong>a_odd</strong>: Away team&#39;s winning odd.</li></ul><h3>Data Cleaning</h3><p>I already had a pretty clean dataset, so I only had to prepare the data for performing a much more robust feature engineering in the next step. In this step I:</p><ul><li>Transformed date into datetime.</li><li>Changed odd columns to float.</li><li>Got beginning year of a season.</li><li>Split match name into home and away teams.</li><li>Split scores into home and away score.</li><li>Created feature with the match result.</li></ul><p>After these transformations, this is what the dataset looked like:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/990/1*DAVc7HMLvY1cMC2_YOnSpQ.png" /><figcaption>Source: <a href="https://github.com/Caldass/pl-matches-predictor">My Github code</a></figcaption></figure><h3>Feature Engineering</h3><p>This is one of the most impactful parts of the project. One can create the best and most complex Machine Learning algorithms possible, stack and tune models as much as one wants, but at the end of the day a simple model with features that explain the relationship between the dependent and independent variables well enough is going to be much more efficient.</p><p>Since it’s only possible to obtain match statistics after a match, the features that would be created had to be based on information that could be obtained before a match.</p><p>First, I created regular statistics such as wins, losses, goals scored and suffered and team position in the table up to the respective match date in the respective season. I also created features such as average goals and points in the last 3 games and the team&#39;s current win, loss and draw streak. The feature I was the most curious to try out was the Weighted Exponential Average, which, according to <a href="https://towardsdatascience.com/what-ive-learnt-predicting-soccer-matches-with-machine-learning-b3f8b445149d">this article</a>, might be a good fit for soccer predictions.</p><p>Here&#39;s the dataset columns info after the feature engineering process:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/1f44968934699921f15112e4e57699b7/href">https://medium.com/media/1f44968934699921f15112e4e57699b7/href</a></iframe><p>Note that some columns contain null values. I’ll get to them later in the model building phase.</p><p>All the features descriptions are inside a file called <em>“features.txt”</em> in the <a href="https://github.com/Caldass/pl-matches-predictor/blob/master/model_building/model.py">Github repo</a> of the project.</p><h3>EDA</h3><p>The goal here was to perform a brief data exploration in order to better understand the relationships between the dependent and independent variables.</p><p>The dataset contained 3 possible classes in the target variable, home team winning, away team winning and draw. The classes had the following proportions:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/229/1*qcB3EwmBnDaGoSiVgCEPBQ.png" /><figcaption>Source: <a href="https://github.com/Caldass/pl-matches-predictor">My Github repo</a></figcaption></figure><p>It’s possible to see that the dominant class is the home team winning, which makes sense since it’s common knowledge that in soccer the home team usually has more advantage.</p><p>One can assume from this that it would be more difficult to predict a draw than to predict a win from one of the two teams, since 75.45% of the dataset contains matches that one of the two teams had the victory.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/578/1*qxqCx3hqFUgt_CyZwgRUBw.png" /><figcaption>Source: <a href="https://github.com/Caldass/pl-matches-predictor">My Github repo</a></figcaption></figure><p>In the picture above, it&#39;s possible to see the highest 5 features in correlation with each class and each class in a separate dataframe. We can interpret these positive correlations by assuming that if a variable goes up, so does the chance of the class positively correlated to it happen.</p><p>We can see that in the <em>winner_h</em> and <em>winner_a</em> dataframes (home win and away win), what seems to influence the class happening is how bad the other team is doing. For example, the other team’s odds and rank are the ones with the highest correlation.</p><p>Meanwhile, in the <em>winner_d</em> dataframe (draw), which had a very low correlation compared to the other two dataframes, it’s possible to see that the features that are the more correlated to a draw outcome are features that say how bad the home team is doing.</p><p>In the modeling phase I used a feature selection tool, which I’ll talk about later, and performed a brief analysis of the distributions and scatter plots of 13 features selected by the tool.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*bLpN02Ml4iO9xdjAoEPA7w.png" /><figcaption>Source: <a href="https://github.com/Caldass/pl-matches-predictor">My Github repo</a></figcaption></figure><p>In the histograms shown above we can see that the features aren’t normally distributed and are also in different scales. That’s why I applied them the MinMaxScaler transformation in the modeling phase.</p><p>It was also possible to see the relationship between the features through a pairplot:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*miilJFLnBoE4uU82a_4NGg.png" /><figcaption>Source: <a href="https://github.com/Caldass/pl-matches-predictor">My Github repo</a></figcaption></figure><p>Some linearities we could observe from this plot:</p><ul><li>The w.e.a. points have a positive correlation with the w.e.a. goals metric and a negative correlation with the w.e.a. goals suffered metric, which makes perfect sense. If a teams makes more points, it’s going to score more goals and suffer less goals.</li><li>The home team&#39;s odd goes up as the w.e.a. points and w.e.a. goals of the away team also goes up. Which means that the more the away team scores, the less the chance of the home team winning.</li><li>The draw odd is also sort of correlated to both teams&#39; odd, probably because every game is going to have a team with a higher odd, and the draw odd tends to be near the higher odd.</li><li>We can also see some obvious linearities, such as the home team odd going down as the away team rank goes up. Which means that the lowest the away team’s position in the table, the higher the chance of the home team winning.</li></ul><h3>Model Building</h3><p>First, I removed all features that wouldn’t be available before a match and were only used in order to create other features.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/f2d07976e7876f2589b2c2994d2eb89b/href">https://medium.com/media/f2d07976e7876f2589b2c2994d2eb89b/href</a></iframe><p>For the columns with null values I filled them with a “-33” value to help our models interpret them. This way, I allow the model to understand that there’s a reason for these values to be null. For example, in the “_rank” column, if a team doesn’t have a last rank it’s either because the match belongs to the first season present in the dataset or because this specific team wasn’t in the Premier League in the previous season.</p><p>Models used:</p><ul><li><strong>Logistic Regression</strong> — Linear model expected to work due to the linear relationships between features.</li><li><strong>Random Forest Classifier</strong> — Tree based ensemble model expected to work well due to the sparsity of the data.</li><li><strong>Gradient Boost Classifier</strong> — Just like Random Forest, a tree based ensemble model expected to work well due to the sparsity of the data.</li><li><strong>K-nearest neighbors Classifier</strong> — Non supervised learning algorithm where an object is classified by a plurality vote of its K nearest neighbors.</li></ul><p>Before training the models, I split the data into training and test set with a test size of 20%, created dummy columns for the “ls_winner” column and scaled all features using the <a href="https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.MinMaxScaler.html">sklearn MinMaxScaler</a>.</p><p>To evaluate these models I chose the accuracy metric, since the model’s job is to predict the exact match result, no matter what class it belongs to.</p><p>Accuracy is the total number of correct predictions divided by the total predictions. It’s the proportion of correct predictions in our model.</p><p>Here are the models trained and their training results:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/580/1*gilITNSyUUABX6D88aJqGg.png" /><figcaption>Source: <a href="https://github.com/Caldass/pl-matches-predictor">My Github repo</a></figcaption></figure><p>Even though the accuracy levels weren’t too high, it’s important to notice that the best model performed better than just a random prediction or a “<em>home team always wins</em>” prediction, meaning our model was able to explain some of the data.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/419/1*rN827lTzeRdcRWmB9727_w.jpeg" /><figcaption>Source: <a href="https://github.com/Caldass/pl-matches-predictor">My Github repo</a></figcaption></figure><p>Given that Logistic Regression had the best training results, it was the model focused along the modeling phase.</p><p>Since there were more than 40 features in total, I performed a feature selection using the <a href="https://scikit-learn.org/stable/modules/generated/sklearn.feature_selection.RFE.html">Recursive Feature Elimination (RFE)</a> method.</p><p>Feature selection is important to:</p><ul><li>Increase the model explainability.</li><li>Reduce training time.</li><li>Avoid the <a href="https://en.wikipedia.org/wiki/Curse_of_dimensionality">curse of dimensionality</a>.</li><li>Reduce overfitting.</li></ul><p>The method used selects features by recursively considering smaller and smaller sets of features. In this graph, it&#39;s possible to see the relationship between amount of features used versus the accuracy level of Logistic Regression:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/640/1*4q3gcRnzTT3EGcpQrnithQ.png" /><figcaption><a href="https://github.com/Caldass/pl-matches-predictor">Source: My Github repo</a></figcaption></figure><p>Not only was it possible to maintain the level of accuracy to a satisfactory level, but it was possible to even increase the level of accuracy at a certain number of features. I selected 13 as the ideal number of features so that we could have more explainability and the accuracy level difference was minimum compared to using all features.</p><p>These were the features selected:</p><ul><li>h_odd</li><li>d_odd</li><li>a_odd</li><li>ht_rank</li><li>at_rank</li><li>ht_l_points</li><li>at_l_points</li><li>at_l_wavg_points</li><li>at_l_wavg_goals</li><li>at_l_wavg_goals_sf</li><li>at_win_streak</li><li>ls_winner_-33</li><li>ls_winner_HOME_TEAM</li></ul><p>We can observe that all the odds features were selected. This highlights their importance. It’s understandable since bookmakers do a great job at creating odds and predicting matches. We can also notice that the features with information about ranking are present, alongside the average points in the last 3 matches.</p><p>The Weighted Exponential Average features also worked their way into the top 13 features but only on the away team side.</p><p>Note that the “ls_winner_-33” means that there weren’t last matches between the 2 teams, which apparently is also important to state the match outcome.</p><h3><strong>Simulating Investment</strong></h3><p>Here, I used the test data as a simulation of an investment in betting markets using the model’s predictions and the matches’ odds.</p><p>The simulation contained test data of 1216 matches. I settled a fictional investment of $100 per match, making a total investment of $121,600.</p><p>Here’s how the model is performed:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/500/1*NWxkuzJsdV-_yj4_O2oa_Q.jpeg" /><figcaption>Source: <a href="https://github.com/Caldass/pl-matches-predictor">My Github repo</a></figcaption></figure><p>What is noticeable is that the KNN algorithm also had profit, even though it had the worst accuracy among the 4 algorithms in the training phase.</p><p>To understand why the KNN model had profit and the other 2 models didn’t, we need to clarify what’s precision, recall and F1-score:</p><ul><li><strong>Precision</strong>: Of all the predicted positives, how many were actually positive?</li><li><strong>Recall</strong>: Of all positives, how many did the model said it was positive?</li><li><strong>F1-score</strong>: The harmonic mean of precision and recall.</li></ul><p>Note that these metrics are calculated for each class, so the metric considers the referred class 1 (positive class) and the other two classes 0 (negative class).</p><p>Here’s the <a href="http://scikit-learn.org/stable/modules/generated/sklearn.metrics.classification_report.html">classification report</a> of each model:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/786/1*EoMYuD9osUE1BtnGAbV0FQ.png" /><figcaption>Source: <a href="https://github.com/Caldass/pl-matches-predictor">My Github repo</a></figcaption></figure><p>The class 0 is a draw, the class 1 is away team wins and class 2 home team wins.</p><p>It’s possible to see that even though the KNN model had the lowest accuracy, out of all models it had the best F1-score in the draw class by far. Besides that, it had almost 50% accuracy and a F1-score in the winning classes not very distant from the other models. That’s why the model still had profit in its predictions.</p><p>Logistic Regression didn’t predict correctly any occurrence of the draw class, probably because there wasn’t much linear relationships that pointed out to a draw outcome. But it still had profit because it did a good job predicting the winning classes.</p><h3>Productionization</h3><p>Here, I built a Flask API endpoint, which I deployed to a Heroku application.</p><p>The application is available and hosted at <a href="https://pl-matches-predictor.herokuapp.com/predict">https://pl-matches-predictor.herokuapp.com/predict</a>. The input should be as follows:</p><ul><li><strong>h_odd</strong> — Float number that represents the home team&#39;s winning odd.</li><li><strong>a_odd</strong> — Float number that represents the away team&#39;s winning odd.</li><li><strong>d_odd </strong>— Float number that represents the draw odd.</li><li><strong>ht_rank</strong> — Integer that represents the home team’s current rank.</li><li><strong>at_rank </strong>— Integer that represents the away team’s current rank.</li><li><strong>ht_l_points </strong>— Average home team points in the last 3 games.</li><li><strong>at_l_points </strong>— Average away team points in the last 3 games.</li><li><strong>at_l_wavg_points</strong> — Weighted Exponential Average away team&#39;s points in the last 3 games.</li><li><strong>at_l_wavg_goals</strong> — Weighted Exponential Average away team&#39;s goals in the last 3 games.</li><li><strong>at_l_wavg_goals_sf </strong>— Weighted Exponential Average away team&#39;s goals suffered in the last 3 games.</li><li><strong>at_win_streak</strong> — Integer that represents the away team’s current win streak.</li><li><strong>ls_winner </strong>— Last match winner between both teams (“HOME_TEAM, “AWAY_TEAM”, “DRAW”). If there wasn’t a last match don’t fill this input.</li></ul><p>The output of the request is a Data Frame containing a “prediction” column with the match predicted outcome.</p><p>Here’s a Python example of the request:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/f6f89915eb0f8cc644af9d8ae718c6dc/href">https://medium.com/media/f6f89915eb0f8cc644af9d8ae718c6dc/href</a></iframe><h3>Improvements</h3><p>In the future, if I would try and implement improvements in the profit and accuracy level, I probably wouldn’t use Logistic Regression. Even though other models in this particular project didn’t have the profit L.R. did, they have shown more potential to predict all 3 classes outcomes.</p><p>Also, creating new features and adding external data such as how many fans are present and in game stats like shots on target and fouls committed may help improve the accuracy and profit level.</p><h3>Conclusion</h3><p>Even though predicting soccer matches is not an easy task, I found the results of this project very satisfying considering it was possible to not only have an accuracy score better than just a random prediction or a “<em>home team always wins</em>” prediction. But it was also possible to beat the odds, having a profit percentage on an investment simulation of approximately 4.81% using the model’s prediction.</p><p>If you wanna see more details about the project or contribute to it, check its <a href="https://github.com/Caldass/pl-matches-predictor">Github repo!</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a1c3445b285a" width="1" height="1" alt=""><hr><p><a href="https://medium.com/analytics-vidhya/beating-soccer-odds-using-machine-learning-project-walkthrough-a1c3445b285a">Beating soccer odds using Machine Learning — Project Walkthrough</a> was originally published in <a href="https://medium.com/analytics-vidhya">Analytics Vidhya</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Estimador de aluguéis na cidade do Recife — Visão geral do projeto]]></title>
            <link>https://arthurmlcaldass.medium.com/estimador-de-alugu%C3%A9is-na-cidade-do-recife-vis%C3%A3o-geral-do-projeto-d96e29b9ac29?source=rss-6c4414fd7a7------2</link>
            <guid isPermaLink="false">https://medium.com/p/d96e29b9ac29</guid>
            <category><![CDATA[python]]></category>
            <category><![CDATA[flask]]></category>
            <category><![CDATA[ciencia-de-dados]]></category>
            <category><![CDATA[heroku]]></category>
            <category><![CDATA[recife]]></category>
            <dc:creator><![CDATA[Arthur Caldas]]></dc:creator>
            <pubDate>Wed, 28 Apr 2021 14:30:11 GMT</pubDate>
            <atom:updated>2021-04-28T14:30:11.179Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/770/1*NnyqHXELHmU8TvJNZyUaFQ.jpeg" /><figcaption><a href="http://www2.recife.pe.gov.br/servico/cidade-1">Foto pertencente à prefeitura do Recife</a></figcaption></figure><h3>Estimador de aluguéis na cidade do Recife — Visão geral do projeto</h3><p><em>Este projeto foi desenvolvido em inglês a fim de torná-lo útil e acessível a indivíduos do mundo inteiro. Porém, o produto final possui seus inputs em Português tendo em vista o público-alvo como sendo residentes ou futuros residentes da cidade do Recife.</em></p><p>A pandemia tem afetado as mais diversas classes sociais, áreas e setores econômicos. No setor imobiliário não foi diferente.</p><p>Muitas pessoas tiveram suas fontes de renda afetadas pela crise econômica e ficaram sem condições de pagar aluguéis, consequentemente tendo que partir em busca de novas moradias.</p><p>Em tempos normais, procurar um novo imóvel já não é uma tarefa simples, além de que é necessário estar atento para não ser vítima de negociações injustas.</p><p>Tendo esse problema em mente, eu decidi utilizar meus conhecimentos em Ciência de Dados para contribuir com o tema construindo uma ferramenta para prever o valor de aluguel de imóveis na minha região, mais precisamente na cidade do Recife.</p><h3>Extração dos dados</h3><p>Primeiramente era necessário obter os dados de imóveis disponíveis para aluguel em Recife. Para tal, utilizei as informações do site <a href="https://www.vivareal.com.br/">https://www.vivareal.com.br/</a>, um site para anúncio de imóveis. Como o projeto é voltado para aluguéis de residências, foi filtrado apenas anúncios de apartamentos ou casas.</p><p>Para a extração dos dados, foi-se utilizado duas bibliotecas do Python para Web Scraping, o <strong>BeautifulSoup</strong> e o <strong>Selenium</strong>.</p><pre>#exemplo de importação das bibliotecas<br>from bs4 import BeautifulSoup</pre><pre>from selenium import webdriver</pre><p>Tá, mas duas bibliotecas que fazem a mesma coisa?</p><p>Sim e não. O propósito das duas é o mesmo: extrair dados da web. Porém, elas fazem a extração de uma forma bem diferente.</p><p>O BeautifulSoup é uma biblioteca que extrai informações direto de documentos HTML e XML, além de ser bastante <em>user-friendly</em> é a biblioteca para <em>scraping</em> que eu possuo mais familiaridade. Já o Selenium basicamente simula um ser humano no navegador, isso se deve ao fato de que ele foi desenvolvido para testes automatizados de aplicativos e mais tardiamente foi incorporada a função de web scraper.</p><p>Sendo assim, fiz toda a estrutura do <em>scraping</em> no BeautifulSoup enquanto que para clicar na página seguinte me utilizei dos benefícios do Selenium, já que para a próxima página refletir no navegador era necessário um clique na página e não apenas um <em>request</em> com a devida URL.</p><p>O resultado foi um script que varria por alguns minutos todas as páginas do meu determinado filtro e me entregava um Data Frame em formato CSV. A extração dos dados foi feita durante um intervalo de 8 dias, extraindo um novo Data Frame a cada execução para aumentar o número de anúncios únicos finais no Data Frame.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/326/1*c4rK_vtzT48InYsL1Qx5CQ.jpeg" /><figcaption>Data Frames extraídos em csv</figcaption></figure><h3>Limpeza de dados</h3><p>Em seguida, foi preciso agrupar todos os Data Frames e remover todas as observações duplicadas:</p><pre>path = &#39;../scraping/datasets_scraped&#39;<br>all_files = glob.glob(path + &quot;/*.csv&quot;)</pre><pre>li = []</pre><pre>for filename in all_files:<br>    frame = pd.read_csv(filename, index_col=None, header=0, decimal = &#39;,&#39;)<br>    li.append(frame)</pre><pre>#concatenating all datasets and removing duplicate rows (there might be duplicate posts)<br>df = pd.concat(li, axis=0, ignore_index=True)<br>df.drop_duplicates(inplace = True)</pre><pre>df.head()</pre><p>Aqui está uma amostra do Data Frame agrupado:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/983/1*PkWFzSkES2UQqEgSmD_Viw.jpeg" /></figure><p>As colunas são respectivamente: Título, endereço, área (em m²), banheiros, quartos, vagas na garagem, conteúdos extra, aluguel e taxa de condomínio.</p><p>Se observarmos bem, algumas linhas da coluna “<em>fee</em>” (taxa de condomínio) estão nulas e contém símbolos de moeda (R$), assim como algumas colunas, como “<em>bathrooms</em>” (banheiros), estão como objeto e não como número inteiro. Esses e mais pontos identificados precisaram ser tratados para que o projeto pudesse continuar:</p><pre>#removing currency simbols, filling NAs with 0 and turning column into integer<br>df[&#39;fee&#39;] = df[&#39;fee&#39;].str.replace(&#39;.&#39;,&#39;&#39;).str.replace(&#39;$&#39;,&#39;&#39;).str.replace(&#39;R&#39;,&#39;&#39;).str.strip().astype(float)<br>df[&#39;fee&#39;] = df.fee.fillna(0)<br>df[&#39;fee&#39;] = df.fee.astype(int)</pre><pre>#turning into integers columns and replacing strings<br>df[&#39;bathrooms&#39;] = df.bathrooms.str.replace(&#39;--&#39;, &#39;0&#39;)<br>df[&#39;bathrooms&#39;] = df.bathrooms.astype(str).astype(int)<br>df[&#39;parking_spots&#39;] = df.parking_spots.str.replace(&#39;--&#39;, &#39;0&#39;)<br>df[&#39;parking_spots&#39;] = df.parking_spots.astype(str).astype(int)</pre><pre>#filling nas with a empty list and turning string list into list<br>df.extra_contents.fillna(&#39;[]&#39;, inplace = True)<br>df[&quot;extra_contents&quot;] = df[&quot;extra_contents&quot;].apply(eval)</pre><pre>#turning column into integer<br>df[&#39;rent&#39;] = df[&#39;rent&#39;].str.replace(&#39;.&#39;,&#39;&#39;)<br>df[&#39;rent&#39;] = df.rent.astype(int)</pre><h3>Feature Engineering</h3><p>Podemos entender <em>Feature Engineering</em> como a extração de novas informações utilizando os dados brutos a fim de criar novas variáveis que nos ajudem a entender melhor os dados e melhorar nosso modelo preditivo.</p><p>A coluna “<em>title</em>” (título) pode não parecer tão útil para o projeto, porém, ela foi utilizada para construir uma variável que informava se um imóvel era uma casa ou um apartamento:</p><pre>#defining if a property is a house or a apartment<br>df[&#39;property_type&#39;] = df.title.apply(lambda x: x.split()[0].strip().lower())</pre><pre>#changing names from Brazilian Portuguese to English<br>df.replace({&#39;property_type&#39; : { &#39;apartamento&#39; : &#39;apartment&#39;, &#39;casa&#39; : &#39;house&#39;}}, inplace = True)</pre><p>A fim de extrair informações de geolocalização, fiz <em>geocoding</em> da variável de endereço através da biblioteca Geopy, gerando uma coluna chamada “<em>location</em>” (localização) a qual foi utilizada posteriormente para gerar informações de bairro, latitude e longitude do respectivo imóvel:</p><pre>from geopy.extra.rate_limiter import RateLimiter<br>from geopy.geocoders import Nominatim<br>from geopy.exc import GeocoderTimedOut</pre><pre>#creating geopy objects<br>locator = Nominatim(user_agent = &#39;myGeocoder&#39;)<br>geocode = RateLimiter(locator.geocode, min_delay_seconds=1)</pre><pre>#function to avoid timeout<br>#orginal code found on <a href="https://gis.stackexchange.com/questions/173569/avoid-time-out-error-nominatim-geopy-openstreetmap">https://gis.stackexchange.com/questions/173569/avoid-time-out-error-nominatim-geopy-openstreetmap</a><br>def do_geocode(address, attempt=1, max_attempts=5):<br>    try:<br>        return locator.geocode(address, addressdetails=True)<br>    except GeocoderTimedOut:<br>        if attempt &lt;= max_attempts:<br>            return do_geocode(address, attempt=attempt+1)<br>        raise</pre><pre>#getting location data from geocode<br>df[&#39;location&#39;] = df[&#39;address&#39;].apply(lambda x: do_geocode(x))</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/994/1*w93gQFLsxovdp8I1-9l5jg.jpeg" /><figcaption>Data Frame com nova coluna “location”.</figcaption></figure><p>Foram feitas <a href="https://medium.com/data-hackers/vari%C3%A1veis-dummy-o-que-%C3%A9-quando-usar-e-como-usar-78de66cfcca9">colunas dummy</a> dos itens na coluna de conteúdos extra, ou seja, uma nova coluna equivalente à cada item era gerada, a qual indicava 1 se o conteúdo estivesse presente naquele respectivo imóvel e 0 caso contrário.</p><p>Isso foi feito não apenas para explorar cada item futuramente mas também porque dessa forma o modelo conseguirá quantificar essas variáveis categóricas (não numéricas). Como seriam muitas colunas provenientes dessa transformação, foram filtradas apenas os 5 itens com maior correlação com a variável dependente (aluguel): “Mais de um andar”, “Mobiliado”, “Churrasqueira”, “Cozinha” e “Piscina”.</p><p>Também foi criada uma variável de distância do imóvel até a praia. Para isto, utilizei dados da cobertura vegetal da cidade disponibilizados pela <a href="http://dados.recife.pe.gov.br/dataset/cobertura-da-terra">Dados Recife</a>. Através da biblioteca Geopandas foi convertida cada área da cobertura vegetal classificada como praia em latitudes e longitudes e no fim foi calculada a mínima distância da praia até o respectivo imóvel:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/751/1*qYkMYsJZGLYzW5L38kRKeg.jpeg" /><figcaption>Algumas das novas colunas criadas.</figcaption></figure><h3>EDA (Análise Exploratória)</h3><p>Nesta etapa o objetivo era entender, explorar e visualizar os dados, entendendo também a relação entre as variáveis e, talvez, detectar alguma discrepância que não foi possível detectar na etapa de limpeza de dados.</p><p>Foi notável logo de primeira mão que havia algum problema:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/831/1*JEotfIRivsRsIfRbpYHfEQ.jpeg" /><figcaption>Distribuição dos aluguéis</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/443/1*pUsiFvVIlXQUUJWT4DQ3VA.jpeg" /><figcaption>Gráfico de caixa dos aluguéis</figcaption></figure><p>Quase não é possível enxergar a distribuição dos aluguéis no histograma, porém, no gráfico de caixa é possível ver que existem alguns <a href="https://www.aquare.la/o-que-sao-outliers-e-como-trata-los-em-uma-analise-de-dados/">outliers</a> muito acima dos demais. Após verificar afundo, notou-se que haviam dados de imóveis comerciais classificados erroneamente como residenciais. Estes eram os casos:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/688/1*Nci20gzDxcmVZi-0hPpAVA.jpeg" /></figure><p>Além disso, também foram identificados imóveis que provavelmente foram preenchidos de maneira errada ou não eram verídicos:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/928/1*dyqQIgaqJOALcAkbyz9ujg.jpeg" /><figcaption>Gráfico de dispersão area x aluguel</figcaption></figure><p>Neste gráfico de dispersão é possível ver que estes imóveis aparentam ter sua área muito próxima de 0 e com um alto aluguel. Aqui estão exemplos:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/602/1*auAbEr_j7jFpSq8zVlcyEw.jpeg" /></figure><p>Após corrigir estes erros, foi dada sequência à analise com gráficos como o mapa de correlação:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*g4d-B5cZAYfBUBAFTyKW7w.jpeg" /></figure><p>Através desse gráfico foi possível entender melhor o relacionamento entre as variáveis dependentes e independentes, como por exemplo o fato de a distância da praia e o aluguel serem inversamente proporcionais, ou seja, quanto menor a distância do imóvel da praia, maior o valor do aluguel.</p><p>Também foi possível perceber correlação entre as variáveis latitude e longitude com a distância da praia, o que poderia prejudicar nosso modelo preditivo mais na frente, tendo em vista que não é um bom sinal variáveis independentes possuírem alta correlação.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/819/1*EoQyyza09FstPZ7LQcWnxQ.png" /><figcaption>Distribuição do aluguel</figcaption></figure><p>Plotando novamente o histograma do aluguel podemos ver que temos uma <a href="https://pt.wikipedia.org/wiki/Assimetria_(estat%C3%ADstica)"><strong>distribuição positivamente assimétrica</strong></a><em>. </em>Isso se deve à grande quantidade de <em>outliers</em> presente nos nossos dados, porém, esse <em>outliers</em> não são erros e sim imóveis residenciais com valores acima do normal, como por exemplo apartamentos beira mar (os quais realmente tendem a ter valores mais exagerados).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*uzrzhGARW5NzxJSP3R7Phg.png" /><figcaption>Aluguel mediano por bairros com mais de 29 anúncios.</figcaption></figure><p>No gráfico acima buscou-se entender quais bairros eram os mais caros através da mediana, exibindo também sua distância da praia (linha verde) e o número de exemplos daquele bairro presentes no Data Frame (linha vermelha).</p><p>Para minha surpresa, Boa Viagem não é o bairro mais caro de acordo com nossos dados, mesmo sendo o bairro com o maior número de exemplos ele é apenas o terceiro mais caro.</p><p>Vale ressaltar que devido aos <em>outliers</em> já comentados, foi preferível utilizar a mediana ao invés da média para que houvesse menor influência destes na classificação dos bairros.</p><p>A fim de entender melhor os dados por bairro foi construído gráficos interativos de caixa, em que poderia ser avaliado a variação dos dados de acordo com o filtro de bairro selecionado. Também foi feito um gráfico de mapa utilizando a biblioteca Folium:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/414/1*DVUfGGiRL0cCSpdjHCczyw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/979/1*IEn4zW-JbysOqeQbAhQ8Gw.png" /></figure><blockquote>Para interagir com os gráficos acesse o link de visualização do notebook disponível no <a href="https://nbviewer.jupyter.org/github/Caldass/rental_properties/blob/main/eda/eda.ipynb">nbviewer</a>!</blockquote><p>Por fim, normalizamos nossas variáveis de área e aluguel, já que ambas são positivamente assimétricas, através da transformação logarítimica. Dessa forma podemos melhorar nosso modelo preditivo, o qual assume que os dados se aproximam de uma distribuição normal.</p><pre>#Transforming column<br>df[&#39;rent&#39;] = np.log(df[&#39;rent&#39;])</pre><pre>#Transforming column<br>df[&#39;area&#39;] = np.log(df[&#39;area&#39;])</pre><p>Após as transformações podemos dizer que as duas variáveis têm sua distribuição próxima à uma distribuição normal:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/938/1*k9SJUJKTyhgfUKUSGuKD7A.jpeg" /><figcaption>Distribuição do aluguel (azul) x simulação de normalidade (laranja)</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/938/1*DhiUFhPxSowXAlDHV2IkBQ.jpeg" /><figcaption>Distribuição da área (azul) x simulação de normalidade (laranja)</figcaption></figure><h3>Construção dos modelos</h3><p>Para construir o modelo preditivo foram removidas as colunas de latitude e longitude, conforme comentado anteriormente. Ambas estavam altamente correlacionadas com a variável de distância até a praia.</p><p>Os modelos de regressão escolhidos para prever o aluguel foram:</p><ul><li>Regressão Linear</li><li>Regressão Lasso</li><li>Random Forest</li><li>Gradient Boost</li></ul><p>A regressão Linear e Lasso foram escolhidas como as <em>baselines</em> do modelo, isto é, os pontos de corte.</p><p>A regressão linear teve uma performance terrível, pois após transformar as variáveis de bairro em colunas <em>dummy</em>, o Data Frame chegou a ter mais de 70 colunas e consequentemente muitos dados zerados.</p><p>A regressão lasso foi escolhida justamente por não sofrer os efeitos que a regressão linear sofreu, tendo em vista que este é um algoritmo de regularização que aplica penalidades às variáveis.</p><p>Tanto o Random Forest quando o Gradient Boost são modelos que utilizam métodos de <em>ensemble</em> baseados em árvores de decisão, os quais geralmente funcionam bem em dados com alta dimensionalidade.</p><p>Os modelos foram treinados com 80% dos dados e testados com 20%.</p><p>Para avaliar os resultados utilizamos o <strong>erro médio absoluto percentual (MAPE), </strong>pois além de ser fácil de interpretar, não é tão sujeito ao efeito de <em>outliers</em>. Basicamente o modelo diz, em média, o quanto o algoritmo errou nas previsões. Eis os resultados nos dados de treino:</p><ul><li><strong>Regressão Lasso</strong>: MAPE = 3.7%</li><li><strong>Random Forest</strong>: MAPE = 2.2%</li><li><strong>Gradient Boost</strong>: MAPE = 2.5%</li></ul><p>Random Forest teve o menor MAPE, sendo o modelo escolhido para ser tunado no modelo final do projeto.</p><h3>Deploy do modelo em produção</h3><p>Nessa etapa eu construí um <em>endpoint </em>utilizando o Flask API, um web <em>framework</em> para Python, o que significa que ele nos possibilita construir funcionalidades para aplicativos web.</p><p>Após a construção do <em>framework</em> utilizamos a plataforma <a href="https://www.heroku.com/">Heroku</a> para realizar o <em>deploy</em> do nosso modelo.</p><p>Heroku é uma plataforma que nos permite hospedar aplicações como a API que foi construída em um servidor da Web.</p><h3>Produto final</h3><p>A aplicação está disponível e hospedada em <a href="https://rental-properties.herokuapp.com/predict">https://rental-properties.herokuapp.com/predict</a>. Para utilizar a aplicação você deve realizar um input no formato JSON da seguinte forma:</p><ul><li><strong>property_type</strong> — ‘<em>apartamento</em>’ ou ‘<em>casa</em>’.</li><li><strong>address</strong> — <em>‘Avenida Boa Viagem, 5822 — Boa Viagem, Recife — PE’</em> (Endereço no formato: ‘ <strong>rua, número — bairro, Recife — PE’ </strong>ou ‘<strong>bairro, Recife — PE’</strong>)</li><li><strong>area </strong>— 160 (número inteiro que represente a área em metros quadrados).</li><li><strong>bedrooms</strong> — 4 (número inteiro que represente o número de quartos).</li><li><strong>bathrooms </strong>— 3 (número inteiro que represente o número de banheiros).</li><li><strong>parking_spots </strong>— 3 (número inteiro que represente o número de vagas na garagem).</li><li><strong>extra_contents </strong>— <em>“[‘Mais de um andar’, ‘Mobiliado’, ‘Churrasqueira’, ‘Cozinha’, ‘Piscina’]”</em> (Qualquer uma das opções listadas como conteúdos extras do imóvel).</li></ul><p>O <em>output</em> do request é um Data Frame contendo uma coluna chamada “prediction” com o valor previsto do imóvel (com taxa de condomínio incluída), bem como colunas transformadas como distância da praia e bairro por exemplo.</p><p>Eis um exemplo do request feito em Python:</p><pre>import pandas as pd<br>import requests<br>import json</pre><pre>#prediction request url<br>url = &#39;https://rental-properties.herokuapp.com/predict&#39;<br></pre><pre>#headers<br>headers = {&#39;Content-type&#39;: &#39;application/json&#39;}</pre><pre>#input example<br>input_df = pd.DataFrame({&#39;property_type&#39;: [&#39;apartamento&#39;],<br> &#39;address&#39; : [&#39;Avenida Boa Viagem, 5822 - Boa Viagem, Recife - PE&#39;],<br> &#39;area&#39; : [160],<br> &#39;bathrooms&#39;: [5],<br> &#39;bedrooms&#39; : [4],<br> &#39;bathrooms&#39; : [2],<br> &#39;parking_spots&#39; : [3],<br> &#39;extra_contents&#39; : [&quot;[&#39;Mais de um andar&#39;, &#39;Mobiliado&#39;, &#39;Churrasqueira&#39;, &#39;Cozinha&#39;, &#39;Piscina&#39;]&quot;]})</pre><pre>#transform df into json format<br>df_json = input_df.to_json(orient = &#39;records&#39;)</pre><pre>#make request to server<br>r = requests.post( url = url , data = df_json, headers =headers)</pre><pre>#output dataframe with prediction<br>output = pd.DataFrame(r.json(), columns = r.json()[0].keys())</pre><pre>#Print result<br>print(&#39;O valor do imóvel é R$ %.2f&#39; % output.prediction[0])</pre><blockquote>Output: O valor do imóvel é R$6.492,82</blockquote><h3>Conclusão</h3><p>Fiquei bastante satisfeito com o resultado do projeto visto que foi possível construir com sucesso uma ferramenta desde a extração dos dados no site original até o <em>deploy</em> do modelo em produção. Também foi possível adquirir um grande aprendizado com todos os desafios e dificuldades encontradas ao longo dos processos.</p><p>Espero que este projeto possa ser utilizado não apenas como auxílio para pessoas à procura de novos imóveis mas também como ferramenta de aprendizado.</p><p>Se você tem interesse em contribuir com o projeto ou acompanhar com mais detalhes as etapas do mesmo basta visitar <a href="https://github.com/Caldass/rental_properties">o repositório no Github</a>!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d96e29b9ac29" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[My story]]></title>
            <link>https://arthurmlcaldass.medium.com/my-story-e3e3a9461ee8?source=rss-6c4414fd7a7------2</link>
            <guid isPermaLink="false">https://medium.com/p/e3e3a9461ee8</guid>
            <category><![CDATA[python]]></category>
            <category><![CDATA[storyofmylife]]></category>
            <category><![CDATA[data-science]]></category>
            <dc:creator><![CDATA[Arthur Caldas]]></dc:creator>
            <pubDate>Fri, 31 Jul 2020 03:27:46 GMT</pubDate>
            <atom:updated>2021-08-03T18:39:24.135Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*gwh4ElgPDfTIF0AfGxrdxQ.jpeg" /><figcaption>Photo by <a href="https://unsplash.com/@franki">Franki Chamaki</a> on <a href="https://unsplash.com/">Unsplash</a></figcaption></figure><p><a href="https://medium.com/@arthurmlcaldass/minha-hist%C3%B3ria-771f466f70a5">Leia em português</a></p><p>I am a Commercial Intelligence Assistant that wishes to working with Data Science and is currently a Business Major at Universidade Federal of Pernambuco (UFPE).</p><p>When I first started college, I thought I wanted to work with different companies, human resources, customer service and possibly even managing a business of my own. After the first six months in school, I got an internship at one of the biggest distributor companies in my home state, Cardeal Distribuidora, which has been an amazing opportunity for me to learn more about the field and to begin my career.</p><p>While working for Cardeal, I have been lucky to be under the guidance of someone who is an expert at Excel and its resources and who is also extremely professional and compassionate. In a short period of time, my boss turned me into an expert in those tools as well as other ones, such as Power BI and a little bit of SQL, always following the well known mantra of “The student must surpass their master.” Eventually, I fell in love with writing formulas, M-code (Power Query language), and data in general.</p><p>A few months after I started at Cardeal as an intern, I became a full-time employee and my boss introduced me to Data Science. After doing my own personal research, I realized I was made for that field. It was actually a little bit similar to what I was already doing at my job every day, dealing with data.</p><p>However, not only do I work full-time, I also take night classes at my university and both of these things consume 90% of my time, making it difficult for me to focus, study, and start a career in Data Science.</p><p>Today, it has been over a year since I became full-time at Cardeal and have been working as a Commercial Intelligence Assistant, which helps me to maintain a consistent knowledge about data and to learn as much as possible. Since my classes have been canceled due to the pandemic and I had to start working from home, I found the perfect opportunity to dive in head-first in the Data Science world. I have realized that there was a lot that I had been missing. Even though I have studied as much Data Science as I could for the past year, it wasn’t until the quarantine started that I could really focus on my studies.</p><p>Statistics, math, Python, R, Machine Learning, and many other subjects, tools and programs have become a part of my daily tasks and projects. The need and desire to learn more about the field seems to grow every day.</p><p>While studying and learning about Data Science, I found out that creating a blog seems to be a great way to share my abilities, knowledge and projects. This is why I have decided to create my own profile here at Medium.</p><p>This is my story (so far)!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e3e3a9461ee8" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Minha história]]></title>
            <link>https://arthurmlcaldass.medium.com/minha-hist%C3%B3ria-771f466f70a5?source=rss-6c4414fd7a7------2</link>
            <guid isPermaLink="false">https://medium.com/p/771f466f70a5</guid>
            <category><![CDATA[storyofmylife]]></category>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[python]]></category>
            <dc:creator><![CDATA[Arthur Caldas]]></dc:creator>
            <pubDate>Fri, 31 Jul 2020 03:08:22 GMT</pubDate>
            <atom:updated>2021-04-28T14:44:30.469Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*gwh4ElgPDfTIF0AfGxrdxQ.jpeg" /><figcaption>Photo by <a href="https://unsplash.com/@franki"><strong>Franki Chamaki</strong></a><strong> </strong>on <a href="https://unsplash.com/"><strong>Unsplash</strong></a></figcaption></figure><p><a href="https://medium.com/@arthurmlcaldass/my-story-e3e3a9461ee8">Read this in english</a></p><p>Sou um Auxiliar de Inteligência Comercial que almeja trabalhar com Ciência de Dados e atualmente cursa Administração na UFPE.</p><p>Quando entrei na faculdade, sempre havia me imaginado envolvido com gestão, organizações, lidando com pessoas e tentando me imaginar gerindo um negócio. Após meus primeiros 6 meses na faculdade, eu consegui uma vaga como jovem-aprendiz na Cardeal Distribuidora, uma das maiores distribuidoras de Pernambuco, que tem sido uma baita oportunidade para aprender mais e começar minha carreira.</p><p>Tive a sorte de ser alocado em um setor com uma pessoa que era especialista em Excel e seus suplementos, além disso, era uma pessoa com um coração gigante e um baita profissional. Ele me tornou em pouco tempo um excelente usuário do programa e de outras ferramentas como o Power BI e até mesmo um pouco de SQL, sempre com a filosofia de que “O aprendiz deve superar o mestre”. Aos poucos, eu fui criando uma paixão por escrever fórmulas, código na linguagem M (linguagem do Power Query), e mexer com dados de uma forma geral.</p><p>Alguns meses após meu ingresso como aprendiz, fui efetivado na equipe do setor e logo em seguida meu chefe me apresentou um novo universo que ele havia recém conhecido na época chamado <strong>Ciência de Dados</strong>. Eu, após pesquisar sobre, me identifiquei instantaneamente. Aquilo de certo jeito era parecido com o que eu já lidava no dia-a-dia, trabalhar com dados.</p><p>Porém, eu não só trabalho integralmente como também faço faculdade à noite, e isso consome 90% do meu tempo, dificultando minhas tentativas de estudar Ciência de Dados e tentar focar nessa carreira.</p><p>Hoje, se passou 1 ano desde que fui efetivado. Tenho a função de um Auxiliar de Inteligência Comercial na minha empresa, o que me ajuda à manter um relacionamento constante com dados e aprender bastante. Desde o recesso das minhas aulas, devido à pandemia que estamos enfrentando, e um consequente home office, eu encontrei a oportunidade perfeita para mergulhar de cabeça no mundo da Ciência de Dados. Embora eu estivesse estudando o máximo que eu podia no último ano, só foi no início da quarentena que eu pude realmente focar nos estudos da área.</p><p>Estatística, matemática, Python, R, Machine Learning, e muitos outros temas e ferramentas tem sido parte do meu dia a dia desde então. Já há algum tempo não restam dúvidas de que essa é a carreira que quero seguir, a vontade e necessidade de aprender aparenta crescer à cada dia que passa.</p><p>Durante meus estudos, descobri que um blog é uma excelente forma de ganhar visibilidade, expor projetos, conhecimentos, aprendizados e até mesmo ajudar outras pessoas com esses aprendizados. Por isso, decidi criar meu perfil aqui no Medium.</p><p>Essa é minha história (até o momento).</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=771f466f70a5" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>