擅长:python、mysql、java
<p>将<a href="https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.DataFrame.groupby.html" rel="nofollow noreferrer">^{<cd1>}</a>与<a href="https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.DataFrame.ffill.html" rel="nofollow noreferrer">^{<cd2>}</a>一起使用</p>
<pre><code>df.groupby(['Company']).ffill()
Company Intro Categories Headquarters Founded Date Funding Stage
0 Apple xyz Healthcare, Big Data New York 2018.0 Series A
1 Apple xyz Healthcare, Big Data New York 2018.0 Series A
2 Apple xyz Healthcare, Big Data New York 2018.0 Series A
3 Banana Lier Government Europe 2010.0 Series B
4 Pear NaN NaN NaN NaN NaN
</code></pre>