Let's suppose you want to create a task that loads a CSV file into an HTML file on a daily basis. This task is meant to be part of a PHP script, but you are unfamiliar with PHP and are unsure of how to write the code. Good news, you can use the Sample Data Toolkit UI to figure out this code for you as follows:
1) Go to the app page for the Simple Data Toolkit UI, at the time of this writing it is here: https://www.vis-software.com/#sdtk
2) Click Choose Files.
3) Find the file you want to convert.
4) Click Open.
5) Select the output type you want, for this tutorial we will select HTMLTable.
6) Then for script, select PHP.
7) Then click Download Script.
You will now have a PHP script that uses SDTK to convert the file you selected to an HTML. You can now either run this script or integrate it with another one.
If you need to install SDTK for PHP, you can do it by downloading the latest version from SourceForge, unzipping it, and placing it in your include path. At the time of this writing, this can be found here: https://sourceforge.net/projects/simple-data-toolkit/files/0.1.3/sdtk-php.zip/download
The script will look something like this:
use comsdtktableConverter;
set_include_path(get_include_path().PATH_SEPARATOR.__DIR__.'/lib');
spl_autoload_register(
function() {
= stream_resolve_include_path(str_replace('\\', '/', ) .'.php');
if () {
include_once ;
}
}
);
phpBoot::__hx__init();
Converter::start()->readFile("ga_sample.csv")->csv()->textOnly()->output()->writeFile("ga_sample.htmltable")->htmlTable()->execute();
readfile("ga_sample.htmltable");
?>
from sdtk import com_sdtk_api_GitAPI def printer(data, reader): print(reader.toArrayOfNativeMaps(None)) com_sdtk_api_GitAPI.reposAPI().retrieveData({"owner": "Vis-LLC"}, printer)To retrieve all branches a repo has using Simple Data Toolkit, we can do the following:
from sdtk import com_sdtk_api_GitAPI def printer(data, reader): print(reader.toArrayOfNativeMaps(None)) com_sdtk_api_GitAPI.branchesAPI().retrieveData({"owner": "Vis-LLC", "repo": "Simple-Data-Toolkit"}, printer)To retrieve all the files in a branch using Simple Data Toolkit, we can do the following:
from sdtk import com_sdtk_api_GitAPI def printer(data, reader): print(reader.toArrayOfNativeMaps(None)) com_sdtk_api_GitAPI.filesAPI().retrieveData({"owner": "Vis-LLC", "repo": "Simple-Data-Toolkit", "branch": "main"}, printer)To retrieve the data in a file using Simple Data Toolkit, we can do the following:
from sdtk import com_sdtk_api_GitAPI def printerData(data, reader): print(data) com_sdtk_api_GitAPI.retrieveAPI().retrieveData({"owner": "Vis-LLC", "repo": "Simple-Data-Toolkit-UI", "branch": "main", "path": "index.html"}, printerData)We can also login using a personal access token (https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens)
from sdtk import com_sdtk_api_GitAPI def printerData(data, reader): print(data) com_sdtk_api_GitAPI.instance().setKey("Personal Access Token Here").retrieveAPI().retrieveData({"owner": "Vis-LLC", "repo": "Simple-Data-Toolkit-UI", "branch": "main", "path": "index.html"}, printerData)Atotium News - Business Aggregate - 2024-12-10Federal Reserve to cut rates by 25 bps on Dec. 18, pause in January- Reuters poll https://finance.yahoo.com/news/federal-cut-rates-25-bps-135054884.html The U.S. Federal Reserve is expected to cut interest rates by 25 basis points on December 18, with 90% of economists polled by Reuters predicting this move. Following this, a pause in rate changes is anticipated in late January amidst concerns over rising inflation risks. Economists attribute potential inflationary pressures to President-elect Donald Trump's proposed policies, including import tariffs and tax cuts. The job market's resilience has reinforced expectations for a rate cut, with most economists forecasting the federal funds rate to be reduced to 4.25%-4.50%. However, a majority expect the Fed to hold rates steady at its January meeting. While nearly 60% of economists predict at least three more rate cuts next year, there is no consensus on future actions. The Fed aims to reach a neutral rate that neither stimulates nor restricts the economy, recently assessed at around 2.9%. Inflation forecasts have been elevated, with concerns about inflation risks due to increased tariffs and potential trade disruptions from the incoming administration. The Fed will update its economic forecasts at the December meeting. GM exits robotaxi market, will bring Cruise operations in house https://www.cnbc.com/2024/12/10/gm-halts-funding-of-robotaxi-development-by-cruise.html General Motors (GM) has decided to end its funding for the development of robotaxis by its subsidiary Cruise. Instead, GM plans to integrate Cruise into its larger technical team to focus on developing autonomous systems for personal vehicles. This decision, announced after an investment of over $10 billion in Cruise, is attributed to the competitive robotaxi market, capital allocation priorities, and the extensive time and resources required to scale up. GM bought Cruise in 2016 and plans to increase its ownership to over 97% by early 2025. This move will also reduce Cruise's annual expenditure from about $2 billion by more than half. Cruise, which halted its driverless operations in October 2023, faced regulatory issues including a crash involving a pedestrian and internal problems that contributed to the decision. GM's departure from the robotaxi market occurs as competitors like Waymo, Tesla, and others advance their own autonomous vehicle services. Microsoft Unveils Zero-Water Data Centers to Reduce AI Climate Impact https://finance.yahoo.com/news/microsoft-unveils-zero-water-data-170002064.html Microsoft has introduced a new data center design that requires zero water for cooling its chips and servers, aimed at reducing the climate impact of its expanding data center operations. This new system employs a "closed loop" method, recycling water that is initially introduced during construction without needing fresh supplies afterward. This initiative, launched in August, is expected to save over 125 million liters of water per year per data center. While the data centers will still need fresh water for facilities like bathrooms and kitchens, this new design is part of Microsoft s effort to address the environmental demands of its growing AI services, particularly in hot and dry regions such as Arizona and Texas. Existing data centers will maintain older technologies, but new facilities in Phoenix and Mount Pleasant, Wisconsin, will adopt this zero-water design starting in 2026. Crypto Trading Frenzy Leads Analyst to Hike Price Targets for Coinbase, Robinhood Stock https://www.barrons.com/articles/crypto-coinbase-robinhood-stock-price-target-71f031b2 The article discusses a recent surge in crypto trading activity, prompting an analyst from Needham & Co., John Todaro, to raise price targets for Coinbase and Robinhood. Despite previous muted trading volumes, both platforms are experiencing increased activity. Todaro increased his target for Coinbase to $420 and for Robinhood to $52, while maintaining a Buy rating. The appointment of Donald Trump and his regulatory policy changes favoring the crypto industry are seen as beneficial for these companies. SEC leadership changes and Trump's pro-crypto stance are expected to promote new products and trading on these platforms, with Robinhood aiming to be a leader in crypto and options trading by 2027 and equities by 2029. Bitcoin has reached record highs, motivating a resurgence in trading activity after a period of relative quiet.
Write the right way.
Ortingo is a platform that makes publishing easier and information more accessible. Publish from a wide spectrum of various topics and connect with your audience with new ways of writing articles. Be part of a wealth of new information, through Ortingo.
Ready to write the right way?
Learn more about Ortingo
Any thoughts on Franklin's post?
To comment or reply, you need an Ortingo account.
Sign in or sign upHere's what Ortingoers think of Franklin's post.
There are no comments on this post.