[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"detail-sidebar-cat-0-en-105":3,"doc-seo-588391-105":59,"doc-detail-588391-en":124},{"code":4,"msg":5,"data":6},0,"success",[7,13,18,23,28,33,38,43,48,51,55],{"id":8,"doc_module":4,"doc_module_name":9,"category_name":10,"show_sort_weight":11,"slug":12},1,"Document","Story & Novel",90,"story-novel",{"id":14,"doc_module":4,"doc_module_name":9,"category_name":15,"show_sort_weight":16,"slug":17},2,"Literature",80,"literature",{"id":19,"doc_module":4,"doc_module_name":9,"category_name":20,"show_sort_weight":21,"slug":22},4,"Exam",70,"exam",{"id":24,"doc_module":4,"doc_module_name":9,"category_name":25,"show_sort_weight":26,"slug":27},5,"Comic",60,"comic",{"id":29,"doc_module":4,"doc_module_name":9,"category_name":30,"show_sort_weight":31,"slug":32},6,"Technology",50,"technology",{"id":34,"doc_module":4,"doc_module_name":9,"category_name":35,"show_sort_weight":36,"slug":37},7,"Healthcare",40,"healthcare",{"id":39,"doc_module":4,"doc_module_name":9,"category_name":40,"show_sort_weight":41,"slug":42},8,"Research & Report",30,"research-report",{"id":44,"doc_module":4,"doc_module_name":9,"category_name":45,"show_sort_weight":46,"slug":47},9,"Religion & Spirituality",20,"religion-spirituality",{"id":46,"doc_module":4,"doc_module_name":9,"category_name":49,"show_sort_weight":46,"slug":50},"World Cup","world-cup",{"id":52,"doc_module":4,"doc_module_name":9,"category_name":53,"show_sort_weight":52,"slug":54},10,"Lifestyle","lifestyle",{"id":56,"doc_module":4,"doc_module_name":9,"category_name":57,"show_sort_weight":24,"slug":58},19,"General","general",{"code":4,"msg":60,"data":61},"ok",{"site_id":62,"language":63,"slug":64,"title":65,"keywords":66,"description":67,"schema_data":68,"social_meta":117,"head_meta":119,"extra_data":121,"updated_unix":123},105,"en","using-the-eric-api-for-research-topics-how-to-use-eric-api-for-research-topics","Using the ERIC API for Research Topics - How to use ERIC API for research topics","","Guide on using the ERIC API to retrieve and analyze education research topics. Shows how to import required Python libraries, build a reusable request function with parameters like search, format, pagination, and returned fields, and compute record counts for a query. Provides utilities to fetch all records across pages, clean empty list elements, inspect returned columns, select subsets of fields, and export results to an Excel file for downstream analysis.",{"@graph":69,"@context":116},[70,84,99],{"@type":71,"itemListElement":72},"BreadcrumbList",[73,77,79,82],{"item":74,"name":75,"@type":76,"position":8},"https://docshare.wps.com","Home","ListItem",{"item":78,"name":9,"@type":76,"position":14},"https://docshare.wps.com/document/",{"item":80,"name":30,"@type":76,"position":81},"https://docshare.wps.com/document/technology/",3,{"item":83,"name":65,"@type":76,"position":19},"https://docshare.wps.com/document/using-the-eric-api-for-research-topics-how-to-use-eric-api-for-research-topics/588391/",{"url":83,"name":65,"@type":85,"author":86,"headline":65,"publisher":89,"fileFormat":92,"inLanguage":63,"description":67,"dateModified":93,"datePublished":93,"encodingFormat":92,"isAccessibleForFree":94,"interactionStatistic":95},"DigitalDocument",{"name":87,"@type":88},"Putri","Person",{"url":74,"name":90,"@type":91},"DocShare","Organization","application/pdf","2026-10-15",true,{"@type":96,"interactionType":97,"userInteractionCount":4},"InteractionCounter",{"@type":98},"ViewAction",{"@type":100,"mainEntity":101},"FAQPage",[102,108,112],{"name":103,"@type":104,"acceptedAnswer":105},"What parameters does the getEricRecords function use for ERIC API requests?","Question",{"text":106,"@type":107},"It uses search criteria plus format, start for pagination, rows for page size, and fields to specify which record fields to return.","Answer",{"name":109,"@type":104,"acceptedAnswer":110},"How does the notebook determine how many records a search will return?",{"text":111,"@type":107},"The getRecordCount utility calls getEricRecords for the query and reads the numFound value from the returned data frame.",{"name":113,"@type":104,"acceptedAnswer":114},"How are all records for a query fetched and cleaned?",{"text":115,"@type":107},"getAl1EricRecords repeatedly calls getEricRecords with increasing start offsets until all results are collected, then applies cleanElementsUsingList to convert empty lists to None.","https://schema.org",{"og:url":83,"og:type":118,"og:title":65,"og:site_name":90,"og:description":67},"article",{"robots":120,"canonical":83},"index,follow",{"doc_id":122,"site_id":62},588391,1792065149,{"code":4,"msg":5,"data":125},{"doc_id":122,"user_id":126,"nickname":87,"user_avatar":127,"doc_module":4,"category_id":29,"category_name":30,"doc_title":65,"doc_description":67,"doc_content":128,"file_id":129,"file_url":130,"file_type":131,"file_size":132,"view_count":4,"is_deleted":4,"is_public":8,"is_downloadable":8,"audit_status":8,"page_count":19,"language":133,"language_code":63,"site_id":62,"html_lang":63,"table_of_contents":134,"faqs":135,"seo_title":136,"seo_description":67,"update_tm":123,"read_time":52},962085571259,"https://ap-avatar.wpscdn.com/davatar_29158cc5080c5b710cf443261637dec0","# Using the ERIC API for Research Topics\n\nThis Jupyter Notebook demonstrates how to use the ERIC APl to research topics.This example uses Python and the Pandas library.The ERIC APl supports any programming language that supports making HTTPS requests.Other popular choices include JavaScript,C\\#,and Java.  \nImport required Python libraries  \nWe start by importing the Python libraries used in this notebook.  \n\n| 1   \u003Cbr>2  \u003Cbr>3  \u003Cbr>4  \u003Cbr>5  \u003Cbr>6   \u003Cbr>7  \u003Cbr>8   | import numpy as np  \u003Cbr> import pandas as pd  \u003Cbr> import requests  \u003Cbr> import json  \u003Cbr> import time  \u003Cbr>import matplotlib.pyplot as plt  \u003Cbr> import seaborn as sns  \u003Cbr> sns.set()   |\n| --- | --- |\n\nIn []:  \nNext we create a function to make ERIC API requests  \nThe following function(getEricRecords)calls the ERIC API when invoked.It takes five parameters:  \n·search -the search criteria.See the ERIC APl docs (https://d170fiyqpmf5gt.cloudfront.net/index.html\\#/default/get eric)for details.  \n·format -the response format.Valid values are xml(default),json,and csv.  \n·start-this parameter supports pagination by specifying the starting record index for the returned record set.The default is 0.  \n·rows-by default,the ERIC API returns 20 records at a time.This parameter can be set to a value between 20 and 200.  \n·fields -specifies the fields to include in the returned records.See the ERIC API docs(https://d170fjygpmf5gt.cloudfront.net/index.html\\#/default/get eric)for details.  \n\n| 1  \u003Cbr>2  \u003Cbr>3  \u003Cbr>4  \u003Cbr>5  \u003Cbr>6  \u003Cbr>7   |  def getEricRecords(search,fields =None,start=0,rows=200):  \u003Cbr>url ='https://api.ies.ed.gov/eric/?'  \u003Cbr>ur1=ur¹+'search='+search +'&rows='+str(rows)+'&format=json&start='+str(start)  \u003Cbr>if(fields):  \u003Cbr>url =url +'&fields='+','.join(fields)  \u003Cbr>responseJson =requests.get(url).json()  \u003Cbr>return pd.DataFrame(responseJson)   |\n| --- | --- |\n\nIn []:  \nGet Number of Records for Search  \nThis utility function returns the number of records returned by the ERIC API for a given search.  \n\n| 1   \u003Cbr>2  \u003Cbr>3  \u003Cbr>4  \u003Cbr>5   | def getRecordCount(search):  \u003Cbr>dataFrame =getEricRecords(search)  \u003Cbr>totalRecords =dataFrame.loc['numFound'][0]  \u003Cbr>print('Search',search,'returned','{:,}'.format(totalRecords),'records')  \u003Cbr>return totalRecords   |\n| --- | --- |\n\nIn[]:  \nCreate function to get all records for an ERIC API search  \nThe following function getAllEricRecords calls the getEricRecords function as many times as needed to fetch all records in an ERIC APISearch.If a set of return fields are not specified,the Frequently used fields (https://d170fjvqpmf5gt.cloudfront.net/index.html\\#/default/get eric)will bereturned.  \nThe cleanElementsUsingList function cleans the resulttig datframe from showing empty lists in some fieds where the ERI API returns an emptylist.  \n\n| 1 def cleanElementsUsingList(x):  \u003Cbr>2  \u003Cbr>if(not isinstance(x,list)):  \u003Cbr>3  \u003Cbr>return x  \u003Cbr>if(not x or(len(x)==1 and x[0]=='')):  \u003Cbr>4  \u003Cbr>5  \u003Cbr>return None  \u003Cbr>6  \u003Cbr>return','join(x)  \u003Cbr>7  \u003Cbr>8  \u003Cbr>9 def getAl1EricRecords(search,fields =None,cleanElements =True):  \u003Cbr>startTime =time.time()  \u003Cbr>10  \u003Cbr>nextFirstRecord =0  \u003Cbr>11  \u003Cbr>numRecordsReturnedEachApiCall =200  \u003Cbr>12  \u003Cbr>totalRecords =getRecordCount(search)  \u003Cbr>13  \u003Cbr>if(totalRecords ==0):  \u003Cbr>14  \u003Cbr>print('Search',search,'has no results')  \u003Cbr>15  \u003Cbr>return []  \u003Cbr>16  \u003Cbr>17  \u003Cbr>while(nextFirstRecord \u003CtotalRecords):  \u003Cbr>18  \u003Cbr>dataFrame =getEricRecords(search,fields,nextFirstRecord)  \u003Cbr>19  \u003Cbr>if(nextFirstRecord ==0):  \u003Cbr>20  \u003Cbr>records =pd.DataFrame(dataFrame.loc['docs'][0])  \u003Cbr>21  \u003Cbr>else:  \u003Cbr>22  \u003Cbr>records =pd.concat([records,pd.DataFrame(dataFrame.loc['docs'][0])],sort=False,ignore_index=T  \u003Cbr>23  \u003Cbr>nextFirstRecord +=numRecordsReturnedEachApiCall  \u003Cbr>24  \u003Cbr>print('took','{:,.1f}'.format(time.time()-startTime),'seconds')  \u003Cbr>25  \u003Cbr>return records.applymap(cleanElementsUsingList)if cleanElements else records  \u003Cbr>26   |\n| --- |\n\nIn []:  \n## Example of making ERIC API requests\n\nSo","cbCaialLFzxBF66f","https://ap.wps.com/l/cbCaialLFzxBF66f","pdf",1934927,"English","# Using the ERIC API for Research Topics\n## Import required Python libraries\n## Create function to make ERIC API requests\n## Get Number of Records for Search\n## Create function to get all records for an ERIC API search\n## Example of making ERIC API requests\n## Write retrieved records to an Excel file","[{\"question\":\"What parameters does the getEricRecords function use for ERIC API requests?\",\"answer\":\"It uses search criteria plus format, start for pagination, rows for page size, and fields to specify which record fields to return.\"},{\"question\":\"How does the notebook determine how many records a search will return?\",\"answer\":\"The getRecordCount utility calls getEricRecords for the query and reads the numFound value from the returned data frame.\"},{\"question\":\"How are all records for a query fetched and cleaned?\",\"answer\":\"getAl1EricRecords repeatedly calls getEricRecords with increasing start offsets until all results are collected, then applies cleanElementsUsingList to convert empty lists to None.\"}]","Using the ERIC API for Research Topics - How to use ERIC API for research topics | PDF"]