Urgent.News

What's breaking now, across thousands of outlets.

Tech

Xếp hạng bài cũ cần làm mới từ file xuất Search Console bằng pandas

Báo cáo Hiệu suất của Google Search Console đủ để chọn bài cũ nên tối ưu lại, nhưng lọc tay vài trăm URL rất mệt. Bài này dùng pandas trên file xuất của Search Console để xếp nhóm bài theo hai con số: lượt hiển thị và lượt nhấp, rồi tìm truy vấn mà bài chưa trả lời. Dữ liệu đầu vào Xuất hai file từ báo cáo Hiệu suất: tab Trang (URL, lượt nhấp, lượt hiển thị, CTR, vị trí) cho hai khoảng thời gian…

Original Spanish Read in English

Google Search Console reports can help identify old pages that need optimization, but filtering through hundreds of URLs can be tedious. Pandas, a Python library, can simplify the process by grouping pages based on two key metrics: impressions and clicks. The script first reads two data files from the report, each containing the same time period, such as a yearly comparison. If needed, query data can be fetched via the API or by filtering individual URLs.

The script then imports the pandas library and defines a function to group pages into four categories based on clicks and impressions. The function calculates the median values for impressions and clicks, and assigns each page to one of the four categories based on these metrics and the median values. The grouped pages are then sorted by category and impressions in descending order.

To further refine the results, the script checks if a page's click-through rate (CTR) is both high and low, and assigns it to a separate category for review. This ensures that the script considers the industry-specific variations in typical CTR rates. Finally, the script identifies pages that are declining in performance compared to a previous period.

By setting the median value of the website as the threshold, rather than a fixed number, the script accommodates the varying CTR rates across different industries and keywords.

Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.

Read the original at dev.to →

More in Tech

After the SOC Assessment: Common Findings and How to Fix Them

After the SOC Assessment: Common Findings and How to Fix Them _ Got your SOC assessment report back? Here are the findings that show up most often and a practical plan to remediate them._ The report…

  • Organize SOC assessment findings into high-risk/low-effort and high-risk/high-effort categories
  • Implement quick wins like updating contact info and confirming vital log sources
  • Establish basic metrics (detection time, response time) for current capabilities

I built a cross-API rate limit reference because I was tired of guessing

I kept hitting 429s on APIs I use daily. Every time, I'd search "Stripe rate limit" or "OpenAI rate limit" and land on a docs page that told me about one API, in one tier, with no error shape and no…

  • Developer created cross-API rate limit reference to avoid guessing limits.
  • Documented maximum requests per minute (RPM) and transactions per minute (TPM) for each API tier.
  • Included retry logic and JSON structure of 429 response with Retry-After header.

More from Thursday 5 November →