R blogdown/pagedown and Github

Not as easy as I thought

It’s taken all day to get blogdown to sync with Github. I already had a repo set up at https://tedtwong.github.io/ and I had set up a blogdown folder in R Studio, let’s call it: R/blogdown.

I wasn’t too familiar with how to set up git to sync the R/blogdown/public folder with https://tedtwong.github.io/ repo so that I can version control blogdown files and host the files on Github at the same time. What worked for me was to clone https://tedtwong.github.io to R/blogdown/ and then change the folder name to ‘public’. That way it only synced the public files once blogdown does its thing.

Now I can edit the files in blogdown and then use git to sync with github.io and everything works pretty well. One note of caution: put stuff (for example media files, etc.) into the contents folder and not directly into the public folder since rebuilding the blogdown site will overwrite the public folder from the contents folder.

I hope this helps someone in the same predicament.

I also created a resume using pagedown resume template. The code is here:

---
title: "Teddy Wong's resume"
author: Teddy Wong
date: "2022-07-19" 
output:
  pagedown::html_resume:
    css:
      - override.css #overide css defaults
      - resume #default file
    # set it to true for a self-contained HTML page but it'll take longer to render
    self_contained: TRUE
# uncomment this line to produce HTML and PDF in RStudio:
knit: pagedown::chrome_print
---

# Aside {#aside}
It's easy to understand something once you understand it.

<center>
![Teddy Wong](teddywong.jpg){width="90%"}
</center>

## Contact Info {#contact}

-   <i class="fa fa-envelope"></i> [teddy.t.wong\@gmail.com](mailto:teddy.t.wong@gmail.com){.email}
-   <i class="fa fa-github"></i> [tedtwong.github.io](https://tedtwong.github.io/)
-   <i class="fa fa-phone"></i> +1 510.684.6176

## Skills {#skills}

-   <i class="fa fa-globe"></i> Insurance/insurtech business development.

-   <i class="fa fa-pen"></i> Reinsurance treaty underwriting. Agriculture, weather, and parametric risks.

-   <i class="fa fa-seedling"></i> Global crop insurance market and public/private partnerships.

-   <i class="fa fa-calculator"></i> Applied statistical analysis, models, and optimization methods.

-   <i class="fa fa-code"></i> R, Python, SQL, Tableau, Matlab, GitHub, Quarto.

-   <i class="fa fa-handshake"></i> Collaboration, communication, problem-solving, presentation, research, and adaptability.



## Disclaimer {#disclaimer}

This resume was made with the R package [**pagedown**](https://github.com/rstudio/pagedown). 

Last updated on 2022-07-19.

# Main

## Teddy Wong {#title}

## Professional Experience {data-icon="suitcase"}

### AIRM Consulting

Reinsurance and Strategic Partnerships

Los Angeles, CA

Current - 2021

-   Business planning
-   Reinsurance consulting
-   Capital/cash flow/loss modeling
-   Regulatory requirements, ratings, domicile consulting

### Ironshore/Pembroke/Liberty/Hamilton

Regional Agriculture Reinsurance Manager

Los Angeles, CA

2021 - 2015

-   Manage and underwrite global agriculture treaty risk portfolio.
-   Lead reinsurance binder for India and manage delegated underwriting authority in Australia.
-   Lead data science projects involving yield estimation and portfolio optimization.
-   Liaise with clients, brokers, government and academic partners.

### Catlin/XL/AXA

Reinsurance Underwriter

Costa Mesa, CA

2015 - 2012

-   Underwriting crop, livestock, hail, parametric risks.
-   Coordinate with local branches in N.America, Asia, Europe, Australia.
-   Develop new business opportunities

### Endurance Re

Agriculture Reinsurance Underwriting Analyst

Irvine, CA

2012 - 2010

### ERS/USDA

Economist for the Market and Trade Economics Division, Economic Research Service of the U.S. Department of Agriculture. Summer internship.

Washington D.C.

2008

## Education {data-icon="graduation-cap" data-concise="true"}

### University of California, Davis

PhD Candidate, Agriculture and Resource Economics. ABD

Davis, CA

2011

-   Dissertation: "Commodity Futures Markets Under Rational Expectations with a Speculative Fringe: Theory and Evidence"
-   Fields of Interest: Commodities Markets, Development Economics, Industrial Organization, and Econometrics.

### University of California, Berkeley

BA Economics & BA Political Economy

Berkeley, CA

2003

### Certificates

Google Data Analytics 

Online

2022

## Teaching/Research Experience {data-icon="chalkboard-teacher"}

### UC Davis Teaching Assistant

UC Davis

Davis, CA

2008 - 2004

::: concise
-   ARE139 Futures and Options Fall 2008
-   ARE171A, Corporate Finance, Winter 2007
-   BIS20Q, Mathematical Modeling in Biological Sciences, Spring 2006, Fall 2007
-   NPB100Q, Modeling in Neurobiology, Fall 2006, Fall 2007
-   ARE100A, Intermediate Microeconomics, Winter 2004, Summer 2005, Winter 2006
-   ARE106, Econometrics, Winter 2005
-   ARE115A, Development Economics, Fall 2004, Fall 2005
:::

### UC Davis Research Assistant

UC Davis

Davis, CA

2010 - 2003

::: concise
-   Colin Carter/Aaron Smith/Jim Chalfant (Commodity Markets), Winter 08/09, Spring 08/09/10
-   Steve Boucher (Development Economics), Spring 2005
-   Scott Rozelle (Development Economics), Fall 2003, Spring 2004
:::

## Presentations {data-icon="comments"}
### Presenter
"Machine Learning in Agriculture Yield Estimation" at Guy Carpenter Agriculture Rendezvous

New Delhi, India

2017


### Presenter

"Price Dynamics and Their Causes: An Exploration in Futures and Spot Market Interactions" with Aaron Smith at AAEA

Denver, CO

July 2010

### Discussant

"The Impact of the Extreme Events on Commodity Market Volatility" by Peter Went (GARP) at Financial Management Association (FMA)

Reno, NV

October 2009

### Presenter

"Index Trader Effects on Inter-temporal Price Spreads in Commodity Futures" with Colin Carter and Aaron Smith at NCCC-134 (Applied Commodity Price Analysis, Forecasting, and Market Risk Management)

St. Louis, MO

April 2009

### Presenter

"Effects of Factor Markets on Agricultural Production in China" at ERS/USDA Department Presentation

Washington, D.C.

September 2008

### Chair of Contributed Papers Session

"FDI, Firms, Geography, Exchange Rates, and Policy" at International Agricultural Trade Research Consortium (IATRC)

Beijing, China

July 2007


<script type="text/javascript">
(function() {
    var pages 
    var timer = 0;
    var changeDC = setInterval(function() {
        pages = document.querySelectorAll('.pagedjs_page');
        if(pages.length !== 2 && timer <= 5000) {
            timer += 200;
            return;
        }
        if(pages.length !== 2 && timer > 5000) return clearInterval(changeDC);
        var firstPage = pages[0];
        var lastePage = pages[pages.length - 1];
        var aside = firstPage.querySelector('#aside');
        var asideClone = aside.cloneNode();
        asideClone.id = "aside_last";
        var disclaim = document.querySelector('#disclaimer');
        asideClone.appendChild(disclaim);
        lastePage.querySelector('.pagedjs_page_content > div').appendChild(asideClone);
        clearInterval(changeDC);
    }, 200);
})()
</script>

That last bit of code is to move the disclaimer to the second page that I found on Stack Overflow written by Phil.

css and other files are at: https://github.com/tedtwong/tedtwong.github.io/tree/main/page

I adapted the css file from one I found from Jesús Vélez Santiago: https://github.com/jvelezmagic/cv/blob/main/override.css

Now it’s time to fly.

R  blogdown  Github 

See also